The early diagnosis and real-time monitoring of bacterial infections are of great significance for the establishment of integrated diagnosis and treatment systems. In this study, a pH-responsive smart hydrogel patch system, named CABP, was developed to monitor and treat wound infections. CABP has a sandwich structure, with non-woven fabric/chitosan (NF/CS) as the intermediate skeleton layer, Agarose/chitosan/Bromothymol Blue (AG/CS/BTB) hydrogel as the detection layer, and Agarose/chitosan/phthalocyanine (AG/CS/Pc) hydrogel as the treatment layer. When Staphylococcus aureus (S. aureus) infection occurs, the pH of the environment decreases, which triggers the CABP to change from its original blue color to yellow, achieving an intuitive visual transformation. Moreover, the hydrogel patch showed a significant inhibition rate of up to 99.99971 % against S. aureus under 660 nm light radiation, showing a good photodynamic therapy (PDT)/ chemotherapy (CT) synergistic effect. In addition, CABP showed excellent antibacterial and wound healing effects on S. aureus infection in a full-layer skin defect experiment. In short, the patch system is simple to prepare and easy to use, and can provide important research value for the integrated diagnosis and treatment system in biomedical applications.