In this work we provide the first unambiguous demonstration of the advantages of carrying out photocatalytic H2O2 production in a biphasic system, yielding an aqueous H2O2 solution already separated from the photocatalyst as well as from the electron donor with unprecedentedly high H2O2 concentrations (~0.12 M) as compared to other photocatalytic systems. This achievement was enabled by designing a hydrophobic version of poly(heptazine imide) (PHI)-based ionic polymeric carbon nitride in the form of a composite with alkylated silica. The hydrophobized PHI photocatalyst can be selectively suspended in the organic layer of a biphasic system comprising a fatty alcohol and water as two immiscible liquids. Under visible-light irradiation, the hydrophobized PHI-based photocatalyst oxidizes fatty alcohol as electron donor, while at the same time oxygen is reduced to H2O2 that is instantaneously extracted into the aqueous phase. The continuous separation of the produced H2O2 effectively prevents its decomposition at the photocatalyst surface, enabling thus achieving of concentrations of H2O2 in the aqueous phase that are much higher than for conventional light-driven H2O2 production systems. We further demonstrate that effective proton management facilitates the H2O2 production in a biphasic system as evidenced by the strong effect of the proton concentration in the aqueous layer of the biphasic system on the H2O2 production rate, which is ascribed to more effective protonation of the hydrophobized PHI that is one of the key steps towards completion of the two-electron oxygen reduction to H2O2. The long-term photocatalytic experiments confirmed the stability of the hydrophobized photocatalysts for at least up to 96 h without any loss of hydrophobicity and only very minor decrease in activity.