Antibacterial photodynamic therapy (APDT) is an encouraging therapy modality for bacterial infection. In this work, trithiophene aldehyde (3T‐CHO) as a new photosensitizers was isolated from Herba Ecliptae, and tryptophan (Trp) modified 3T‐CHO improve water solubility and reduced phototoxicity. The photosensitizer‐loaded vesicles were incorporated into a gel scaffold to obtain a wound dressing with detection and antibacterial function. Detection of the presence of pathogenic bacteria, such as Pseudomonas aeruginosa, based on the fluorescence signals was highly efficient and sensitive. The cytotoxin produced by the pathogenic bacteria to induce vesicle lysis, thereby the photosensitive antibacterial agent was released from the vesicle to realize the simultaneous intelligent detection and treatment of pathogenic bacteria. Compared with traditional dressings coated with antibiotics, the synthesized dressing avoids the drawback of pathogenic bacteria developing drug resistance. The proposed microbiologically responsive wound dressing could be used as a general methodology for the design and fabrication of bacterium‐responsive functional biomaterials.