Small molecule photosensitizers for combined in vivo tailored cancer diagnostics and photodynamic/photothermal therapy are desperately needed. Monoamine oxidase A (MAO-A)-activated therapeutic and diagnostic compounds provide great selectivity because MAO-A can be employed as a biomarker for associated Tumors. In order to screen photosensitizers with photodynamic therapeutic potential, we have created a range of near-infrared fluorescent molecules in this work by combining dihydroxanthene parent with various heterocyclic fluorescent dyes. The NIR fluorescent diagnostic probe, DHMQ, was created by combining the screened fluorescent dye matrices with the propylamino group, which is the recognition moiety of MAO-A, based on the oxidative deamination mechanism of the enzyme. This probe has a low toxicity level and can identify MAO-A precisely. It has the ability to use fluorescence imaging on mice and cells to track MAO-A activity in real-time. It has strong phototoxicity and can produce singlet oxygen when exposed to laser light. The temperature used in photothermal imaging can get up to 50 °C, which can harm tumor cells permanently and have a positive phototherapeutic impact on tumors grown from SH-SY5Y xenograft mice. The concept of using MAO-A effectively in diseases is expanded by the MAO-A-activated diagnostic-integrated photosensitizers, which offer a new platform for in vivo cancer diagnostics and targeted anticancer treatment.