The design of efficient self-standing hybrid systems for water purification that combines good adsorption properties with high photodegradation ability is highly challenging owing to the difficulty in simultaneously controlling the band structure and porosity of a semiconductor while maintaining its self-standing nature. Here, we report the synthesis of carbon-rich carbon nitride self-standing filters from supramolecular hydrogels composed of melamine and cyanobenzoic acid. The influence of the chemical structure on the properties of the hydrogels and the final films was studied by tuning parameters such as monomer nature, molar ratio, and pyrolysis temperature. Thanks to their ability to combine the adsorption and photodegradation of organic pollutants, the prepared self-standing films showed remarkable activity and stability in flow conditions (> 95 % efficiency after 10 consecutive cycles). Additionally, the photocatalytic activity of the films was assessed in the powder form for the hydrogen evolution reaction and photocurrent generation in a photoelectrochemical cell. The reported work opens opportunities for the controlled synthesis of multifunctional filters for water purification and other energy-related and sustainable technologies.