Energy-efficient photocatalytic production of H2O2 from water holds the potential to replace the anthraquinone process. However, the impracticality of oxygen bubbling in such processes necessitates addressing the H2O2 production in oxygen-deficient environments. Here, we demonstrated the generation of singlet oxygen (1O2) as a highly active water oxidation derivative that redirects the electron flow for H2O2 production in oxygen-deficient environments. Ground-state oxygen was in-situ generated on photocatalysts and undergoes transition to 1O2, surpassing other competitive electron-consuming reactions. Self-generated 1O2 undergoes preferential photo-reduction to H2O2, benefiting from a small activation energy (0.2 eV), facilitated electron trapping rate, adjacent oxidation/reduction sites and suppressed competitive energy transfer from excited-states to air 3O2. A remarkable solar-to-chemical conversion (SCC) efficiency of 0.25 % was obtained for H2O2 generation in oxygen-deficient conditions. This work unveils a novel concept of redirecting electron flow towards H2O2 production, taking advantage of highly active in-situ generated 1O2.