Solar water disinfection catalyzed by metal-free photocatalyst has emerged as a promising approach for clean water production. By using the edge-functionalized graphitic carbon nitride (g-C3N4) as photocatalytic disinfectants, we find that the pathogen-rich water can be rapidly purified in 30 min with a disinfection efficiency of over 99.9999% under visible-light irradiation, which meets the requirement for drinking water. The edge-functionalized g-C3N4 shows a first-order disinfection rate that is five times higher than the previously reported best metal-free photocatalyst but only consumes 1/10 of the catalyst. The catalytic activity is also comparable to that of the best metal-based photocatalyst. Results of the highest occupied molecular orbitals and Mulliken charge distribution reveal that the exposed –COOH and C=O groups at the edges of g-C3N4 nanosheets not only significantly promote charge separation but also induce the upward bending of the surface band, facilitating the generation of hydrogen peroxide.