In this study, 5,10,15,20-(4-hydroxyphenyl) porphyrin (THPP) was used as an optical waveguide (OWG) sensing material to detect several harmful acidic gases and volatile organic compounds. With this material, the sensor showed high selectivity and sensitivity to NO 2 . First, a OWG sensor based on THPP was prepared using the spin-coating method. Next, the absorbance changes in the porphyrin film before and after interaction with NO 2 gas were analyzed using an ultraviolet-visible spectrophotometer. A 670 nm detection light source was selected for testing the OWG detection system; the optimum conditions were studied, where the lowest concentration detected by the sensor was 10 ppb. The film thickness (190 nm) was measured using scanning electron microscopy (SEM). Thereafter, the gas-sensing mechanism was further investigated through SEM, IR, and x-ray diffraction. Finally, the influence of ambient humidity on the sensor was analyzed. The results showed that ambient humidity can be neglected. The transducer exhibited uncomplicated fabrication and easy portability, and the detection process of OWG could be conducted at ambient temperature and resist electromagnetic interference.