Photodynamic therapy (PDT) is an effective cancer treatment method with high spatiotemporal selectivity and minimal off-target toxicity, yet its clinical translation remains constrained by inadequate aqueous dispersibility, suboptimal biological compatibility, together with photosensitivity-associated adverse reactions of conventional photosensitizers. In this study, four kinds of covalent organic frameworks (COFs) based on triazine or benzene cores with varied donor groups were synthesized, and their optoelectronic properties were then systematically investigated. Among them, TAPT-DVA-COF exhibited the best photodynamic effect under 650 nm light exposure, producing pronounced suppression of tumor progression in vivo . This study demonstrates the application of COFs as promising candidates for safe and effective photosensitizers, with the potential to further advance PDT in cancer treatment.