Non-Metal-Doped Porous Carbon Nitride Nanostructures for Photocatalytic Green Hydrogen Production

Photocatalytic green hydrogen (H2) production through water electrolysis is deemed as green, efficient, and renewable fuel or energy carrier due to its great energy density and zero greenhouse emissions. However, developing efficient and low-cost noble-metal-free photocatalysts remains one of the daunting challenges in low-cost H2 production. Porous graphitic carbon nitride (gCN) nanostructures have drawn broad multidisciplinary attention as metal-free photocatalysts in the arena of H2 production and other environmental remediation. This is due to their impressive catalytic/photocatalytic properties (i.e., high surface area, narrow bandgap, and visible light absorption), unique physicochemical durability, tunable electronic properties, and feasibility to synthesize in high yield from inexpensive and earth-abundant resources. The physicochemical and photocatalytic properties of porous gCNs can be easily optimized via the integration of earth-abundant heteroatoms. Although there are various reviews on porous gCN-based photocatalysts for various applications, to the best of our knowledge, there are no reviews on heteroatom-doped porous gCN nanostructures for the photocatalytic H2 evolution reaction (HER). It is essential to provide timely updates in this research area to highlight the research related to fabrication of novel gCNs for large-scale applications and address the current barriers in this field. This review emphasizes a panorama of recent advances in the rational design of heteroatom (i.e., P, O, S, N, and B)-doped porous gCN nanostructures including mono, binary, and ternary dopants for photocatalytic HERs and their optimized parameters. This is in addition to H2 energy storage, non-metal configuration, HER fundamental, mechanism, and calculations. This review is expected to inspire a new research entryway to the fabrication of porous gCN-based photocatalysts with ameliorated activity and durability for practical H2 production.


Introduction
The inevitable overuse of fossil fuels (i.e., crude oil, natural gas, and hard coal) generate massive greenhouse gas emissions which are the main contributors to global warming and climate change and increased energy crisis [1,2]. Ceaseless efforts dedicated to defeating this issue have culminated in the conversion of gas to useful chemicals [3][4][5][6] and the development of green energy resources such as biofuel [7] and fuel cells (i.e., methanol [8,9], ethanol [10], glucose [11], oxygen evolution [10], oxygen reduction [12,13]). Hydrogen (H 2 ) is one of the most promising green, renewable, and carbon-free fuel or energy carriers, owing to its impressive energy content, earth-abundant resources (i.e., alcohols, methane, and water), and zero greenhouse gas emission [14,15]. H 2 is produced through various processes such natural gas reformation [16,17], biological (i.e., bacteria and microalgae), biomass, and solar (i.e., photobiological, photoelectrochemical, and solar thermochemical) [18][19][20][21]. Unlike these methods, the green H 2 evolution reaction (HER) through water electrolysis driven by electrocatalysts (i.e., Pt, Pd, Ru, and Ir), photocatalysts (i.e., metal  Table 1 shows the focus of the published reviews related to gCN-based nanostructures for H2 production compared with our present review. It is obvious that previous reviews focused on gCN fabrication strategies for photocatalytic H2 production or other  Table 1. Summary of the main reviews related to porous heteroatom-doped porous carbon nitridebased nanostructures for photocatalytic HER compared in the present review.

Title
Focus Ref.
Non-metal-Doped Porous Carbon Nitride Nanostructures for Photocatalytic Green Hydrogen Production Rational design of heteroatoms (i.e., B, N, S, P, F, and O) doped porous carbon nitride for the photocatalytic HER. The effect of mono, binary, and ternary dopants on photocatalytic HER, and their fundamentals and mechanisms are discussed. H 2 energy and storage in addition to HER fundamentals and calculation are also discussed. The current challenges and possible solutions for the synthesis of active gCN photocatalysts for green HERs are also emphasized.

This work
Photocatalytic hydrogen evolution based on carbon nitride and organic semiconductors Organic (i.e., carbon nitride, linear polymers, conjugated porous polymers, and small molecules) for a photocatalytic HER. [33] Solvent-Assisted Synthesis of Supramolecular-Assembled Graphitic Carbon Nitride for Visible Light Induced Hydrogen Evolution-A Review Solvent (i.e., water, DMSO, and water-chloroform) assisted the supramolecular-assembled carbon nitride via hydrogen bonding and hydrogen-halogen interaction. This is in addition to tunable characteristics/properties of photocatalytic HERs. [34] A latest overview on photocatalytic application of g-C 3 N 4 based nanostructured materials for hydrogen production g-C 3 N 4 nanosheets supported metals (i.e., transition metals, non-metals, noble, and semiconductor), and carbon materials (i.e., graphene and carbon nanotubes, and carbon dots) for photocatalytic HER. [35] Preparation, Physicochemical Properties, and Functional Characteristics of Carbon Nitride: a Review Emphasizing various approaches for preparation, and functionalization of porous carbon nitride and their properties that could enhance the photocatalysis, catalysis, and adsorption applications. [41] gC 3
H 2 production. This includes tailoring the physiochemical and photocatalytic merits of porous gCN nanostructures and their photocatalytic H 2 production activity and durability in addition to dissuasion on the optimization of photocatalytic H 2 production as a function of catalyst shape, composition, bandgap, and electrolyte type/concentration. Table 1 shows the focus of the published reviews related to gCN-based nanostructures for H 2 production compared with our present review. It is obvious that previous reviews focused on gCN fabrication strategies for photocatalytic H 2 production or other applications. This is in addition to the formation of heterojunctions structures (Z-scheme, S-scheme, and Type-II scheme) via coupling with other semiconductors (i.e., metal oxides and metal sulfides), carbon materials (i.e., graphene, metal-organic framework, and graphdiyne), and metals/non-metals elements (i.e., Pt, Ag, Ni, Mo, F, and B) for photocatalytic H 2 production and other applications as well. In this review, we collected all the articles related to heteroatom-doped porous gCN nanostructures for H 2 production from the Web of Science, Scopus, and Scifinder databases without bias. Distinct from previous reviews, the main foci of this review are summarized in Table 1, which includes (1) the fundamentals of water electrolysis; (2) the rational design of porous gCN nanostructures functionalized with mono, binary, and ternary heteroatoms (i.e., P, O, S, N, and B) and exploitation of their unique photocatalytic H 2 production properties; (3) H 2 energy and storage; (4) HER fundamental and calculation; (5) discussion on the optimization of the photocatalytic H 2 production and (6) current challenges facing and future remarks on directing the synthesis of porous gCNs for practical applications (Figure 1b).

H 2 as Fuel Strategy
The demand for H 2 increased by nearly three times in the last 3 decades and is expected to continue to rise to reach the net carbon-free emissions target by 2050. The earth resources for H 2 are plentiful, including H 2 O and hydrocarbons (i.e., CH 4 ), and it is easily extracted from fossil fuels (i.e., crude oil, natural gas, and hard coals), biomass, and water [18][19][20][21]. Currently, natural gas is the main source of H 2 production (~95%), which not only consumes almost 6% of global natural gas and 2% for production of 70 million tons annually, but also generates a huge amount of CO 2 emissions [44,45]. Mainly, H 2 production-from crude oil or hydrocarbons-allows complete formation from carbon to CO 2 , while considering the energy for combustion each 1 million SCF of H 2 produces 19.3 metric tons of CO 2 .
H 2 fuel is green and effective, with outstanding energy compared to traditional sources. H 2 has the greatest energy per mass of any other fuel. For example, 1 kg H 2 produces 120 MJ of energy, which is equivalent to 1 gallon of gasoline (44 mJ/kg) and provides 9.1 kg of CO 2 after combustion [14,15]. However, H 2 , due to its inferior ambient temperature density, has a low energy per unit volume. Even in liquid form, H 2 has an energy density of 8 MJ/L compared to gasoline (32 MJ/L) [14,15]. Thus, H 2 requires the rational design of an efficient storage system with potential for greater energy density. H 2 is stored physically as either gas in high-pressure tanks at 350-700 bar or as a liquid that needs cryogenic temperatures owing to the negative boiling point of H 2 (−252.8 • C) at oneatmosphere pressure [18,[46][47][48]. H 2 can also be stored via the adsorption on the surfaces of adsorbents (i.e., MOF, liquid organic, interstitial hydride, complex hydride, and chemical hydrogen) ( Figure 2) [18,[46][47][48]. LiBH 4 -based materials are one of the promising materials for hydrogen storage/release [49][50][51][52][53][54]. However, the thermodynamics and sluggish kinetics of hydrogenation/dehydrogenation is a major obstacle in hydrogen storage/release. Research efforts to improve the hydrogenation/dehydrogenation of this material have utilized multiple approaches. Notably, nanoengineering through techniques like ball milling and confinement in a nanoporous scaffold can reduce grain size and particle size as well as increase the number of defects to allow better diffusion of H 2 and thereby enhanced kinetics of H 2 adsorption/desorption. Another strategy to improve the kinetics of H 2 adsorption/desorption is to dope LiBH 4 with metals such as Ti, metal oxides such as SiO 2 and TiO 2 , and halides such as TiCl 3 . However, the effect of doping is almost negligible on hydrogen re-absorption [50]. Moreover, tuning the thermodynamics of LiBH 4 can allow for better hydrogen adsorption or desorption [49,53]. This can be achieved through partial substitution of the metal cation with metals of a lower electronegativity or the BH 4 anion by elements such as F to yield more thermodynamically favorable adsorption/desorption. Notably, hybrid materials made of Mg(BH 4 ), LiBH 4 , and MgH 2 using a novel fabrication technique has shown to be promising for hydrogen storage/release: 5 wt% in solid state at temperatures <265 • C [49][50][51][52][53][54][55][56]. The hybrid mix is fabricated using room temperature ball milling of MgH 2 with in situ aerosol spraying of LiBH 4 . In addition to experimental efforts, machine learning was employed to predict the hydrogen release ability of LiBH 4 materials and the rank of major variables including sample preparation, mixing conditions, and operational variables [49]. In spite of research efforts to develop and optimize materials for hydrogen storage, the capacity for hydrogen storage is currently very limited and requires high temperatures, which makes it energetically unfavorable. However, further investigations are still needed to develop new storage methods for tanks for more effect delivery and to avoid current challenges. H 2 density shortage remains a daunting challenge for transportation applications, as it needs huge volume systems in gaseous form, so fuel-cell-powered vehicles contain compressed gas onboard storage with large-volume and high-pressure composite vessels that can withstand driving for more than 300 miles and can accommodate large H 2 storage capacity (5-13 kg) onboard [14,15,18,[46][47][48].
for hydrogen storage/release [49][50][51][52][53][54]. However, the thermodynamics and sluggish kinetics of hydrogenation/dehydrogenation is a major obstacle in hydrogen storage/release. Research efforts to improve the hydrogenation/dehydrogenation of this material have utilized multiple approaches. Notably, nanoengineering through techniques like ball milling and confinement in a nanoporous scaffold can reduce grain size and particle size as well as increase the number of defects to allow better diffusion of H2 and thereby enhanced kinetics of H2 adsorption/desorption. Another strategy to improve the kinetics of H2 adsorption/desorption is to dope LiBH4 with metals such as Ti, metal oxides such as SiO2 and TiO2, and halides such as TiCl3. However, the effect of doping is almost negligible on hydrogen re-absorption [50]. Moreover, tuning the thermodynamics of LiBH4 can allow for better hydrogen adsorption or desorption [49,53]. This can be achieved through partial substitution of the metal cation with metals of a lower electronegativity or the BH4 anion by elements such as F to yield more thermodynamically favorable adsorption/desorption. Notably, hybrid materials made of Mg(BH4), LiBH4, and MgH2 using a novel fabrication technique has shown to be promising for hydrogen storage/release: 5 wt% in solid state at temperatures <265 °C [49][50][51][52][53][54][55][56]. The hybrid mix is fabricated using room temperature ball milling of MgH2 with in situ aerosol spraying of LiBH4. In addition to experimental efforts, machine learning was employed to predict the hydrogen release ability of LiBH4 materials and the rank of major variables including sample preparation, mixing conditions, and operational variables [49]. In spite of research efforts to develop and optimize materials for hydrogen storage, the capacity for hydrogen storage is currently very limited and requires high temperatures, which makes it energetically unfavorable. However, further investigations are still needed to develop new storage methods for tanks for more effect delivery and to avoid current challenges. H2 density shortage remains a daunting challenge for transportation applications, as it needs huge volume systems in gaseous form, so fuel-cellpowered vehicles contain compressed gas onboard storage with large-volume and highpressure composite vessels that can withstand driving for more than 300 miles and can accommodate large H2 storage capacity (5-13 kg) onboard [14,15,18,[46][47][48].

Solar-Driven H2 Production
The utilization of solar energy in green H2 production could be carried out through two main approaches including water electrolysis using solar-generated electricity and direct solar water splitting [18][19][20][21]. However, the solar-driven electricity "photovoltaic-

Solar-Driven H 2 Production
The utilization of solar energy in green H 2 production could be carried out through two main approaches including water electrolysis using solar-generated electricity and direct solar water splitting [18][19][20][21]. However, the solar-driven electricity "photovoltaicelectrolysis-fuel cell" should soon be available to make solar-driven H 2 production a feasible process, which is not possible in remote areas or during seasonal variations.
Direct solar H 2 O splitting entails the direct utilization of solar energy in the production of H 2 from water without going through intermediate electrolysis, which includes the following concepts [33][34][35][36][37][38][39][40]: • Photoelectrochemical H 2 O splitting driven by quantum dots or semiconductor (i.e., electrodes using a photoelectrochemical cell) to convert light energy into H 2 chemical energy. Photoelectrochemical systems could be based on semiconductors or dyes and using dissolved metal complexes.

•
The photobiological process includes the production of H 2 from biological systems (i.e., algae and bacteria using sunlight driven by the initial absorption of light by the pigments in algae while the enzymes in the cell act as catalysts to promote H 2 or O 2 production). Both photoelectrochemical and photobiological approaches should be improved significantly to meet large-scale applications because current solar-to-H 2 systems' efficiencies are less than 1%. • Thermochemical cycles for generating high temperature from solar light to produce H 2 , which can achieve efficiencies higher than 40%. However, it needs a concentrated solar receiver/reactors able to generate a high temperature of nearly 800 • C.
According to the US department of energy, photocatalytic water electrolysis is the main pathway for H 2 production to reach the H 2 energy earth-shot aim of decreasing the cost of H 2 by 80% to nearly 1 USD/kg along with zero greenhouse gas emissions by 2031 [57][58][59]. In spite of the great progress made in photocatalytic HERs, the current efficiency is not up to a level that meets practical requirements. In particular, considering daily sunlight illumination (AM 1.5 G) of 7.6 h (assigned to 240 W/m 2 ), to reach a hydrogen price of 3.5 USD/kg, it is estimated that a HER system with an STH of (10%), lifetime of (10 years), decreasing rate of 4%/year, and subsequent acceptable cost of 102 USD/m 2 is required. Therefore, further efforts including both experimental and theoretical studies along with fundamental investigations are needed to develop efficient and low-cost photocatalysts for large-scale photocatalytic HER processes [33][34][35][36][37][38][39][40].
The initial absorption of photons when photon energy is ≥ than the bandgap of gCN to generate electron-hole pairs (e − /h + ) via the excitation of electrons from the valence band (VB) to the conduction band (CB) while the holes are left in the VB: (I) The isolation of the photoexcited carriers into free carriers followed by migration to the active sites of gCN. (II) The initiation of a reduction reaction comprising these charges to produce H 2 on the surface of gCN with the assistance of e − in the CB. The HER reaction in different electrolytes is shown in Equations (1) and (2) In an aqueous solution of acidic electrolyte In an aqueous solution of alkaline electrolyte The overall solar HER efficiency (η total ) is estimated via the kinetics of the above steps together according to Equation (3): where η absorption is the light absorption efficiency that is the fraction of generated e − /h + pairs excited by the incident photon flux, η separation is the charge separation efficiency that is the fraction of photogenerated charge carriers that isolate and migrate to the solid-liquid interface, and η reaction is the reaction efficiency of the gCN surface; that is, the efficiency of the surface reaction involving charge carriers at the solid-liquid interface.
Notably, the lowest band edge of the CB should be lower than the redox potential of H + /H 2 (0 V vs. RHE), and the highest band edge of the VB should be greater than the chemical redox potential of O 2 /H 2 O (Figure 3) [60,61]. Non-metal atoms provide more active sites and reaction centers on the surface of gCN, allowing delay recombination of e − /h + [60,61]. Owing to the ultrafast rate of e − /h + (~ps to ms), they should be promptly captured by the non-metal atoms for promoting the separation and migration of photogenerated charges along with participation in the HER.
The overall solar HER efficiency (ηtotal) is estimated via the kinetics of the above steps together according to Equation (3): where ηabsorption is the light absorption efficiency that is the fraction of generated e − /h + pairs excited by the incident photon flux, ηseparation is the charge separation efficiency that is the fraction of photogenerated charge carriers that isolate and migrate to the solid-liquid interface, and ηreaction is the reaction efficiency of the gCN surface; that is, the efficiency of the surface reaction involving charge carriers at the solid -liquid interface.
Notably, the lowest band edge of the CB should be lower than the redox potential of H + /H2 (0 V vs. RHE), and the highest band edge of the VB should be greater than the chemical redox potential of O2/H2O ( Figure 3) [60,61]. Non-metal atoms provide more active sites and reaction centers on the surface of gCN, allowing delay recombination of e − /h + [60,61]. Owing to the ultrafast rate of e − /h + (~ps to ms), they should be promptly captured by the non-metal atoms for promoting the separation and migration of photogenerated charges along with participation in the HER.  Table 2 summarizes the electrocatalytic HER mechanisms in aqueous solutions of both acidic and alkaline electrolytes. In an aqueous solution of acidic electrolyte, two or three reaction pathways can take place (Equations (4)- (6)) and the HER ensues on the active site of the gCN electrocatalyst (M*):

Electrocatalytic HER Mechanism
(I) A Volmer reaction step that includes a discharge step to allow reduction of protons on the M* and subsequent proton adsorption on M* of gCNs to form gCN-M*Hads (Equation (4)); (II) A Heyrovsky reaction step that involves electrochemical desorption to desorb H2 from the M* via the proton/electron transfer and regenerate of M* Equation (5); (III) A Tafel reaction step that includes the coupling of two adsorbed protons to release H2 and the regeneration of M* (Equation (6)).  Table 2 summarizes the electrocatalytic HER mechanisms in aqueous solutions of both acidic and alkaline electrolytes. In an aqueous solution of acidic electrolyte, two or three reaction pathways can take place (Equations (4)- (6)) and the HER ensues on the active site of the gCN electrocatalyst (M*):

Electrocatalytic HER Mechanism
(I) A Volmer reaction step that includes a discharge step to allow reduction of protons on the M* and subsequent proton adsorption on M* of gCNs to form gCN-M*H ads (Equation (4)); (II) A Heyrovsky reaction step that involves electrochemical desorption to desorb H 2 from the M* via the proton/electron transfer and regenerate of M* Equation (5); (III) A Tafel reaction step that includes the coupling of two adsorbed protons to release H 2 and the regeneration of M* (Equation (6)).
The HER mechanism in an aqueous solution of alkaline electrolyte (Equations (7)-(9)) includes Volmer-Heyrovsky or Volmer-Tafel reaction steps but with the initial dissociation of H 2 O on the M*, due to inferior or low proton concentration in the alkaline electrolyte.
Therefore, the additional energy needed for dissociating H 2 O in alkaline electrolyte is an additional energy barrier of the HER, consequently affecting the overall reaction rate and kinetics. Thus, the HER kinetics in alkaline electrolytes is extremely sluggish relative to acidic electrolytes, owing to more abundant proton donor presence (i.e., H 3 O + ) in acidic electrolytes than (i.e., H 2 O) in alkaline electrolytes. However, noble metals can accelerate the HER rate and kinetics in different electrolytes over broad pH ranges, while few noble-metal-free catalysts can do this. Therefore, it remains a grand challenge to develop electrocatalysts or photocatalysts for HERs over different pH ranges (i.e., acidic, alkaline, and neutral).

HER Measurements and Calculations
The HER process is conducted using various cyclic voltammograms (CVs), impedance spectroscopy (EIS), linear sweep voltammograms (LSVs), chronoamperometry (I-T), Tafel plots, and electrochemical impedance tests in the presence and absence of light. The potential window for a HER in a CV mainly depends on the electrolytes, including (−0.3 to +1 V in the acidic electrolyte) and (+0.3 to −1 V in the alkaline electrolyte); meanwhile, in an LSV the potential direction must be negative (0 to −1 V or 1.5 V)-regardless of the type of electrolyte-to allow for a reduction reaction. The I-T time ranges from a few minutes to several hours based on the catalyst's durability in the electrolyte solution; however, the longterm durability testing takes several weeks. The activity of the gCN-based photocatalysts is determined using the following calculations, summarized in Table 3. Table 3. HER measurements and calculations.

Name Equation Equation No.
Quantum efficiency (QE) QE (%) = number of reacted electrons number of incident photons × 100 (10) Current density (J) J = I/A Over potential (η) Turnover frequency (TOF) TOF = JA/2Fm (13) Reduction current density vs. scan rate Slope = 2nFAΓ0/4RT The turnover frequency (TOF) The quantum efficiency (QE) is calculated using Equation (10) by dividing the number of reacted electrons by the number of the incident photons.
The current density (J) is calculated via the dividing of measured current (I) on the geometric surface area of the working electrode (A) Equation (11). The catalysts should be able to produce an excellent J value under low applied potential (V).
The overpotential (η) is calculated by Equation (12). E is the measured electrode's potential to deliver a current density of 10 mA/cm 2 or more and E o is the standard potential for water splitting (−1.23 V for OER and 0 V for HER). The catalysts should possess a lower η to allow fast HER kinetics.
The turnover frequency (TOF) of each active site is calculated based on J and η by Equation (13), where 2 is the number of moles of electrons consumed in the evolution of one mole of H 2 from H 2 O; F is the Faradic constant (96,485 C/mol), and m is the number of active sites (mol).
The active sites (m) are extracted from the linear relationship between the reduction current densities as a function of sweeping rates, which show a linear relationship. The slope could be obtained from the graph to be used in Equation (14), where n is the number of electrons transferred; Γ0 is the surface concentration of the active sites (mol/cm 2 ); R is the ideal gas constant and T is the absolute temperature.
The TOF can also be calculated using Equation (15), where NA is the Avogadro number, F is the Faraday constant, n is the number of electrons transferred (two for HER and four for OER) to generate one molecule of H 2 or O 2 , and Γ is exact number of active sites catalyzing the reaction per square meter. Therefore, catalysts with abundant active sites should provide higher TOF.
Energy efficiency (E efficiency ) is calculated by Equation (16), where E eq is the equilibrium potential; the energetically efficient catalyst should allow HER at a lower η and with a high E Faradic .
The quantum yield (QY) is calculated from Equation (17), where n x is the moles of the product; N A is Avogadro's constant (6.022 × 1023 mol −1 ); h is Planck's constant (6.626 × 10 −34 J.s); c is the speed of light (3 × 108 m.s −1 ); t ill is the light illumination time; I is the incident intensity (W/cm 2 ) and λ is the wavelength of light (nm); and A is the irradiated area of the cell (cm 2 ).
Non-metal-doped gCNs give the CV features of rectangular shape assigned to high capacitance effect, so the electrochemical active surface area (ECSA) is calculated using the double capacitance (C DL ) via measuring the CV at different scan rates because of N 2saturated aqueous electrolytes (Equation (18)), where C s is the specific capacitance of a flat surface with 1 cm 2 (0.015-0.110 mF/cm 2 in H 2 SO 4 ), (0.022-0.130 mF/cm 2 in NaOH and KOH solutions) depending on the electrolyte concentration [62].
Then the double-layer capacitance (Cdl) is determined via plotting the ∆j = (ja-jc) at 0.1 V as a function of sweeping rate using Equation (19). The Cs is assumed as 20.9 µF/cm 2 for a flat electrode with 1 cm 2 of real surface area [63]. Higher ECSA is an indicator for the greater active sites.
The incident photon to current conversion efficiencies (IPCEs) are calculated using Equation (20), where λ is the wavelength of the incident light, J is the photocurrent density, and I o is the incident light intensity. Thus, photocatalysts with lower bandgap energy can enhance the viable light absorption and provide higher IPCEs.
The Tafel slope is obtained from Tafel plots via plotting the η vs. log J. A greater Tafel slope is an indication of quick HER kinetics and high activity.
The EIS fitting and Voigt electrical equivalent circuit are usually used for fitting the EIS data to obtain electrolyte resistance (R s ), charge transfer resistance (R ct ), and constant phase elements (CPE). The photocatalysts should reveal lower R s and R ct along with higher CPE, made evident by better electrolyte-electrode interaction and quick charge mobility.

Role of Non-Metal Dopants
Non-metal dopants can modulate bandgap energy, augment light absorption, facilitate separation of e − /h + pairs, attract electrons, and enhance the separation and migration of gCN charge carriers ( Figure 4). Moreover, non-metal dopants provide active sites, serve as electron sinks, generate active sites for proton reduction, and improve durability. The minimum theoretical bandgap required to drive the overall water-splitting reaction is 1.23 eV, which corresponds to a wavelength of approximately 1000 nm, so an additional overpotential is usually needed to induce and tune the electron migration process during the HER [60,61]. The reductive decomposition potentials and CBM should be more negative than the H + /H 2 potential to allow thermodynamic durability of gCN-based photocatalysts during the HER [60,61].

Integration of Heteroatoms
The chemical structure of gCNs is still questionable; however, the most recognized structures are triazine or polyheptazine, which possess various unique properties ( Figure  4). The heteroatom elements are integrated via abundant active sites. Figure 4 shows the possible substitution sites of heteroatoms (i.e., B, O, S, P, Cl, Br, I, and F) in gCNs, including the substitution of N atom with (I, S, and O), coordination of P with two N-atoms and replacement of C with B or coordination with F (C-F) ( Figure 4) [60,61]. Heteroatom dopants, with their great inbuilt ionization energies and electro-negativity, can form covalent bonds by gaining electrons when reacting with other compounds. Meanwhile, the physicochemical properties (i.e., size, electronegativity, and chemical state) and location of non-metal dopants can tune the catalytic and photocatalytic properties of gCN.

Integration of Heteroatoms
The chemical structure of gCNs is still questionable; however, the most recognized structures are triazine or polyheptazine, which possess various unique properties ( Figure 4). The heteroatom elements are integrated via abundant active sites. Figure 4 shows the possible substitution sites of heteroatoms (i.e., B, O, S, P, Cl, Br, I, and F) in gCNs, including the substitution of N atom with (I, S, and O), coordination of P with two N-atoms and replacement of C with B or coordination with F (C-F) ( Figure 4) [60,61]. Heteroatom dopants, with their great inbuilt ionization energies and electro-negativity, can form covalent bonds by gaining electrons when reacting with other compounds. Meanwhile, the physicochemical properties (i.e., size, electronegativity, and chemical state) and location of non-metal dopants can tune the catalytic and photocatalytic properties of gCN.

Non-Metal-Doping Configuration and Effects
Unlike noble metals (i.e., Pt, Pd, Au, and Ru) and transition metals (i.e., Co, Cu, and Ni), non-metal dopants are earth-abundant and inexpensive, enhancing electrical conductivity, hydrophilicity, and active sites [60,61,65]. This is due to electron-donating or electron-withdrawing characteristics that tailor the electronic, catalytic, and photocatalytic properties of gCNs. Non-metal atoms can act as trapping sites facilitating the generation of electron-hole pairs, delaying their recombination, and enhancing light absorption under light illumination [60,61]. Table 4 summarizes the main advantages and disadvantageous of heteroatom-doped porous gCN. A N atom, with its size (~155 pm) being close to a carbon atom (~170 pm) but with a larger electronegativity (~3.04) than carbon (2.55) can withdraw electrons, generate abundant active sites, and boost the electronic and ionic conductivity of carbon [6,38,60,61]. Meanwhile, the N atom creates electron-deficiency on its adjacent positive C atom with its negative charge, allowing for a dipole N − -C + bond, which makes gCN more feasible for electrophilic and nucleophilic attack in addition to accelerating charge mobility and facilitating the dissociation of H 2 O molecules during a HER [64,[66][67][68][69][70]. N-doping into gCN can result in N atom pyridinic, pyrrolic/pyridonic, quaternary/graphitic, and pyridine-N-oxide that show binding energy at 398.5, 400.1, 401.1, and 403.2 eV, respectively, as determined by X-ray photoelectron spectroscopy (XPS) [71]. These N atom species are highly active sites for CO 2 RR and other catalytic applications, which induce Lewis basicity on the C atom and act as active sites during HERs.
The boron (B) atom, with a smaller size of (85 pm) and lower electronegativity (2.04) than C, is inserted into the skeleton structure, as it replaces C in the gCN without affecting its planar structure [35,[38][39][40]. B, with its electron-deficiency that accounts for boron being a strong Lewis acid that can easily accept protons, decreases the Fermi level into valance, and promotes charge polarization of gCNs. Moreover, B can decrease the Fermi level into valance, generate multiple defects, enhance visible light absorption, modulate bandgap energy, and enhance the reactivity of gCN [35,[38][39][40]. According to the XPS, there are two main in-plane binding structures of B in gCN, including graphitic B at 200.5 eV and B-substituted C atoms in the hexagonal triazine or polyheptazine rings of co-conjugated gCN at 198.5 eV [72]. Interestingly, B can stabilize the negatively polarized oxygenated atoms during the HER, consequently enhancing H 2 O molecule chemisorption from the electrolyte during the HER process.
Sulfur (S), with a larger size (180 pm) and higher electronegativity (2.58) than carbon, promotes the electrical conductivity and spin density, edge strain, and charge delocalization of gCN via the substitution of the N atom with S in gCN [35,[38][39][40]. Thus, the C-S bond in triazine or polyheptazine at the edges of gCN is easily determined by the XPS at a binding energy of 163.7 eV.
Phosphorus (P), with lower electronegativity (2.19) and large size (195 pm) than C, creates positive charges on P dopant and negative charges on positively charged C. This leads to the formation of (P + -C − ) via the co-coordination of P with two C atoms in triazine or polyheptazine of gCN, which can promote charge mobility and provide plentiful active sites during a HER [35,[38][39][40]. A C-P bond is detected at a binding energy of 132.5 eV.
The oxygen (O) atom has a lower atom size (152 pm) than C but a higher electronegativity (3.44 pm), which increases the positive charge on its neighboring C atom in the form of (C + -O − ) after substitution of N with O in gCNs [35,[38][39][40]. This allows more electron donation to generate additional active sites, boosting the electronic and ionic conductivity of gCN. Additionally, the O atom alters the intrinsic electronic structure of gCN, which is important for controlling the binding energies of reactants and intermediates during HER, due to oxidant functional groups (i.e., C-O, C=O, and C-OH), which can induce in situ formation of active oxygen species (i.e., -OH, O 2 ) needed for activation and dissociation of H 2 O 2 . The XPS can detect C-O bonds at 532 eV and C=O 533 eV. However, the exact location of heteroatoms in the skeleton structure of gCNs and their effect is still ambiguous. Additional theoretical and experimental studies are needed, along with in situ characterization tools, to determine their position and effects during catalytic and photocatalytic reactions.
Thus, engineering the morphology of gCN nanostructures can benefit the separation and movement of photogenerated charge pairs, facilitate mass transfer, and offer more accessible active sites for catalytic reactions [6,28,100,101]. For instance, Zhu et al. proposed a template-free synthesis of mesoporous phosphorus-doped g-C 3 N 4 nanoflowers (P-CN) with in-plane mesopores (3-18 nm) and open-up surface (Figure 5d) by co-condensation and thermolysis of a mixture with ME as g-C 3 N 4 precursor and (hydroxyethylidene) diphosphonic acid as phosphonic source [76]. EDS mapping showed the presence of C, N, and P in P-CN; meanwhile, the XPS analysis demonstrated that P mainly replace C or N in g-C 3 N 4 framework to form P-N or P-C bonds. Compared with pristine g-C 3 N 4 , mesoporous g-C 3 N 4 and g-C 3 N 4 nanosheets, the combination of novel morphology and P doping endows P-CN with excellent H 2 evolution activity. This is seen in the higher H 2 evolution rate of P-CN (104.1 µmol h -1 ) that is 9.29 times more than the bare g-C 3 N 4 reference (11.2 µmol h -1 ), implying the effects of a porous flower-like shape and P-doping, which enhance the mobility of the charge carriers and HER photocurrent as further shown in (Figure 5e). Likewise, P-doped g-C 3 N 4 micro-flowers composed of ultrathin nanosheets were obtained by using phosphoric acid as the P source and cyanuric acid-melamine complex as the supramolecular precursor [97]. The inimitable porous micro-flower, with P doping and high surface area, enhanced the utilization of visible light and promoted isolation separation and mobility in the photogenerated charges, which promoted the H 2 rate by 24 times more than the bulk g-C 3 N 4 flake-like structure. In addition to mesoporous P-doped g-C 3 N 4 3D nanoflower, one-dimensional P-doped hexagonal tubular carbon nitride (P-TCN) was reported in hydrothermal and pyrolysis processes using phosphorous acid and ME as raw materials [91]. As seen from the SEM image (Figure 5f) P-TCN had a hexagonal tube with the layered stack structure that comprised exposed rich pores of 40-60 nm along the tube wall as shown in the TEM image (inset in Figure 4f). According to the UV/Vis light absorption spectra and XPS valence band spectra, the electronic structure of P-TCN changed after P doping relative to bulk g-C 3 N 4 (GCN); the corresponding band structure alignments are depicted in Figure 4g. Photoluminescence (PL) emission can be used to determine the trapping and transfer behavior of photoexcited charges. The PL intensity of P-TCN decreased significantly, indicating a lower recombination rate after P doping compared with GCN ( Figure 5g) due to its hexagonal tube morphology, which provides a short path for the mobility of photogenerated charges and delays their recombination. Figure 5h presents the time course of HERs for GCN, TCN, and P-TCN, in which P-TCN displays the highest hydrogen evolution rate at 67 µmol h −1 because of P doping and its tubular structure. To add, no noticeable deterioration of H 2 evolution rate was observed during four cycles of 20 h, suggesting the robust stability of P-TCN. During the linear sweep voltammetry (LSV) measurements (Figure 5i), the larger hydrogen evolution current density of P-TCN represented enhanced electron transfer compared to that of GCN. Additionally, P-TCN revealed an almost threefold enhancement in photocurrent response compared to GCN (Figure 5j). This implies the significant effect of porous hexagonal tube on boosting the specific surface area and active sites in addition to the effect of P doping on reducing band gap energy, enhancing the electric conductivity, and delaying the recombination of photogenerated electron-hole pairs, which lead to increment of the photocatalytic HER efficiency on P-TCN. A similar P-doped tubular g-C 3 N 4 structure was also obtained via hydrothermal and thermal polymerization processes using ME and sodium pyrophosphate as starting precursors [92]. Afterwards, coral-like porous P-doped g-C 3 N 4 tubes (PCNT) were developed by using dicyandiamide and phytic acid as starting materials [96]. The highest photocatalytic hydrogen evolution rate, 2020 µmol h −1 g −1 , was achieved on PCNT, which is about 4.7-and 22.4-fold compared to that of g-C 3 N 4 tubes and pristine bulk g-C 3 N 4 , respectively. Additionally, Zhang et al. prepared P-doped macro/mesoporous g-C 3 N 4 microrods (CNRs) by direct calcination of ethylene diphosphonic acid-ME complex fiber network [93]. Benefitting from unique morphology and electronic properties, the P-CNRs yield a 5.5 times higher hydrogen evolution rate than pristine g-C 3 N 4 .
In most cases, the doped P atoms only substitute C or N atoms of g-C 3 N 4 to form either a P-N or P-C bond [99,147]. Zhou et al. proposed a thermally induced copolymerization route for P-doped g-C 3 N 4 by using hexachlorocyclotriphosphazene as a phosphorus source and guanidinium hydrochloride as g-C 3 N 4 precursor, respectively [90]. X-ray photoelectron spectra (XPS) and NMR results revealed that the P atoms locate at the corner and bay carbon sites of g-C 3 N 4 network to form P-N bond, and the lone electron from the P atom delocalizes to the Π-conjugated triazine ring. The P doping could modify the electronic structure, surface texture, and electric conductivity of g-C 3 N 4 , leading to improved photocatalytic activity. In another study, Sun and his coworkers realized dual-site doping by using ammonium hypophosphite as the P source, thus regulating the band structure of g-C 3 N 4 , accelerating the charge separation and transfer [98]. Various characterization results indicate that two forms of P-N coordination exist: one is the substitution of carbon atoms in the tris-triazine framework to form P-N bonds, the other is the formation of surface N-P-O bonds. Consequently, the dual-site P-doped g-C 3 N 4 yields a 5.7-fold higher H 2 evolution rate than the pristine catalyst. doped g-C3N4 nanoflakes (PCNNFs) using phytic acid and urea as P source and g-C3N4 precursor, respectively [95]. The ultrathin nanoflakes assembled in a porous network-like shaped enlarged surface area, with broad light adsorption of up to 800 nm, a reduced charge-to-surface migration path in in-vertical-plane and in-plane directions, and improved charge separation and transfer efficiency, which synergistically promoted the outstanding photocatalytic H2 production rate of 15,921 μmol h −1 g −1 and a quantum efficiency of 6.74% at 420 nm.

Sulfur Doping
Sulfur doping has also been used to tune the bandgap and electronic structure of g-C 3 N 4 for enhanced visible light absorption, improved charge separation and transfer, and consequently, photocatalytic performance [104,107,111,148]. For instance, Xu's group fabricated S-doped mesoporous g-C 3 N 4 (mpgCNS) by using thiourea as a precursor and SiO 2 nanoparticles as a template [113]. As evidenced by XPS study, the S atoms tend to replace carbon sites to form an S-N bond. Compared with undoped mesoporous g-C 3 N 4 (mpgCN), mpgCNS can further enhance light absorption in both UV and visible light regions. Moreover, the lowest PL intensity for mpgCNS implies the less recombination tendency of photogenerated electron-hole pairs. As expected, the H 2 evolution rate of mpgCNS is 36% higher than that of mpgCN. Additionally, S-doped 2D graphitic carbon nitride nanosheets (2D-SCN) were prepared by the initial polycondensation of thiourea to in situ doped S into bulk g-C 3 N 4 (denoted as SCN), followed by the thermal oxidation process, as illustrated in Figure 6a [108]. The bulk g-C 3 N 4 (CN) and 2D g-C 3 N 4 nanosheets (2D-CN) were synthesized using urea as a precursor. The thermal oxidation etching for different times 1, 2, and 3 h formed 2D-SCN-1h, 2D-SCN-2h, and 2D-SCN-3h, respectively. This led to a break in the hydrogen bond and reduced the thickness between the 2D layers of g-C 3 N 4 nanosheets alongside the creation of a mesoporous structure. The TEM image of 2D-SCN-3h showed well-defined mesoporous nanosheets with multiple pores (4.4-21.8 nm) (Figure 6b) with an average thickness of 4.0 nm as shown by atomic force microscope (AFM) (Figure 6c). The surface area, porosity (i.e., pore volume and pore diameter), and H 2 production increased significantly after oxidation etching. Thereby, the surface area (226.9 m 2 /g) and pore volume (0.81 cm 3 /g) of 2D-SCN-3h were superior to SCN by 13.66 and 6.23 times, respectively, due to their porous morphology. The XPS displays the presence of C, N, and S; meanwhile, the XPS spectrum of S 2p-in which the weak peak at 163.7 eV is related to the S-C bond by substituting lattice N (Figure 6d)was not similar to the work mentioned above reported by Xu's group. As seen from the transient photocurrent response for three samples in Figure 6e, 2D-SCN-3h possesses a higher current density than SCN due to its porous nanostructure and great surface area that increases active sites, which is beneficial for more highly efficient charge separation. By comparing the photocurrent between 2D-SCN-3h and 2D-CN, it is also proven that S doping can promote charge carrier separation and transfer. According to partial density of states computation, the S-C-N bonds formed by S doping are more effective than O-C-N bond. S doping into a porous morphology can also narrow the band gap and enhance light absorption, thus synergistically improving photocatalytic performance. This is shown in the higher H 2 production rate (127.4 µmol/h) in 2D-SCN-3h than in 2D-SCN-2h (85.8 µmol/h), 2D-SCN-1h (9.7 µmol/h), 2D-CN (41.6 µmol/h), SCN (0.5 µmol/h), and CN (0.4 µmol/h) (Figure 6f). Zhou et al. further regulated the above polymerization process of thiourea by adding NH 4 Cl as a bubble template to obtain g-C 3 N 4 with a porous network [106]. It is deduced that NH 4 Cl can decompose into NH 3 and HCl during polymerization, which contributes to the forming of a porous structure and avoiding agglomeration. Apart from thiourea, trithiocyanuric acid also acts as a widely reported sulfur-containing precursor for S doping [105,110,112]. Luo and his co-workers proposed a one-step thermolysis of thiocyanuric acid approach to preparing ultrathin S-doped holey g-C 3 N 4 nanosheets [110]. The optimum sample can deliver a superior H 2 evolution rate of 6225.4 µmol g −1 h −1 under visible light irradiation, almost 45-fold higher than pristine bulk g-C 3 N 4 . Additionally, an apparent quantum yield of 10% at 420 nm could be yielded. In addition to the nanosheets, nanoporous g-C 3 N 4 microrods were prepared for photocatalytic HER by self-assembling melamine-trithiocyanuric acid supramolecule, followed by calcination [105]. ing NH4Cl as a bubble template to obtain g-C3N4 with a porous network [106]. It is deduced that NH4Cl can decompose into NH3 and HCl during polymerization, which contributes to the forming of a porous structure and avoiding agglomeration. Apart from thiourea, trithiocyanuric acid also acts as a widely reported sulfur-containing precursor for S doping [105,110,112]. Luo and his co-workers proposed a one-step thermolysis of thiocyanuric acid approach to preparing ultrathin S-doped holey g-C3N4 nanosheets [110]. The optimum sample can deliver a superior H2 evolution rate of 6225.4 μmol g −1 h −1 under visible light irradiation, almost 45-fold higher than pristine bulk g-C3N4. Additionally, an apparent quantum yield of 10% at 420 nm could be yielded. In addition to the nanosheets, nanoporous g-C3N4 microrods were prepared for photocatalytic HER by self-assembling melamine-trithiocyanuric acid supramolecule, followed by calcination [105]. CN. Adapted with permission from Ref. [108]. 2020, American Chemical Society.

Boron Doping
B-doped porous ultrathin g-C3N4 nanosheets (CNB NS) were prepared by the initial hydrothermal treatment of an aqueous solution of melamine and barbituric acid for 10 h at 180 °C, followed by annealing at 550 °C for 2 h [116]. In their synthesis, barbituric acid (BA) not only assemble with melamine to generate a porous structure but also replace the Adapted with permission from Ref. [108]. 2020, American Chemical Society.

Boron Doping
B-doped porous ultrathin g-C 3 N 4 nanosheets (CNB NS) were prepared by the initial hydrothermal treatment of an aqueous solution of melamine and barbituric acid for 10 h at 180 • C, followed by annealing at 550 • C for 2 h [116]. In their synthesis, barbituric acid (BA) not only assemble with melamine to generate a porous structure but also replace the triazine ring of the heptazine unit in the g-C 3 N 4 framework. As references, CNH was obtained via the hydrothermal and annealing methods but without barbituric acid and CN was synthesized by direct heating of melamine at 550 • C for 2 h. The SEM image of CNB NS showed the formation of porous nanosheets (Figure 7a) and the TEM image revealed that the nanosheets are ultrathin with multiple in-plane pores and curled edges (Figure 7b) with an average thickness of 3-4 nm (Figure 7c). This reflects the effect of annealing and hydrothermal treatment in presence of barbituric acid on the morphology as further seen by the BET surface area of CNB NS (55.07 m 2 /g) being 3.26 times greater than CN (16.88 m 2 /g). XPS analysis revealed the higher ratio of the C1s peak at 284.6 eV in CNB NS compared to in CN, owing to the incorporation of B-doping; however, the peak of the B-based dopant does not appear in the XPS survey and there is no other quantitative analysis to confirm presence of B. The UV-vis diffuse reflectance spectra (DRS) showed a red shift of the band edge absorption of CNB NS of 30 nm more than CN, implying that incorporating BA could decrease Π-deficiency and induce an asymmetric electron density. As reflected by the electronic band structure in Figure 7b, the conduction band of CNB NS shows a negative shift of 0.16 eV compared to that of CN, which implies the effect of a porous ultrathin curled nanosheet shape on reducing photoexcited electrons as seen in the lower band gap energy of CNBS (2.69 eV) than CN (2.78 eV), which is characteristic of the generation of photogenerated electron-hole pairs and delays their recombination. This is seen in the photocurrent-time curves, which indicate the quick and uniform photocurrent responses on all samples but with a superior activity on CNB NS (Figure 7d). The photocurrent responses were reversible under each dark/light circulation, which implied a higher photocurrent in light than under dark. Furthermore, CNB NS showed the highest hydrogen evolution rate at 1323.25 µmol h −1 g −1 , which is almost 13 times higher than that of CN (Figure 7e). This is due to its porous nanostructure with great surface area, which provides more exposed catalytic active sites along with the prevention of nanosheet aggregation during the HER as shown in the stability of CNB NS for five cycles without any apparent attenuation of the H 2 evolution rate. Figure 7f displays the wavelength-dependent apparent quantum efficiency (AQE) of H 2 evolution for CNB NS, and the AQE decreases with the increased wavelength due to the light-induced HER, implying enhanced visible light harvesting. In another study, B-doped carbon nitride nanotubes were fabricated by a simple hydrothermal treatment of boric acid and melamine, followed by calcination [117]. Although the band structure of carbon nitride was not changed after B doping, the fully exposed active sites and high-density charge carriers endowed them with a highly efficient and stable hydrogen evolution rate.

Oxygen Doping
Oxygen-doped g-C 3 N 4 was first prepared using a facile H 2 O 2 hydrothermal approach [122]. As evidenced by the XPS result, O atoms could be incorporated into the matrix and substitute sp 2 -hybridized nitrogen atoms in g-C 3 N 4 to form C-O and N-C-O species. Moreover, a negative shift in the conduction band minimum was observed after O doping, whereas the valence band maximum remained unchanged. As a result, the O doping could adjust the electronic and band structure, resulting in extended visible light response, enlarged surface areas, and suppressed charge carrier recombination. In another study, Huang et al. reported the synthesis of O-doped g-C 3 N 4 with a porous network by condensation of supramolecular aggregates formed by melamine and H 2 O 2 [123]. They found that the control over the O-dopant amount is significant, and excess dopants could serve as defect sites for electron-hole recombination. The optimal catalysts delivered 6.1 and 3.1 times higher HER activity than pristine and porous g-C 3 N 4 and an apparent quantum efficiency of 7.8% at 420 nm. Guo and his coworkers synthesized holey-structured g-C 3 N 4 with edge oxygen doping using a photo-Fenton reaction in the presence of Fe 3+ /Fe 2+ and H 2 O 2 . Based on the various characterization technique, oxygen edge doping can remarkably broaden light harvesting capacity and improve charge separation efficiency. a higher photocurrent in light than under dark. Furthermore, CNB NS showed the highest hydrogen evolution rate at 1323.25 μmol h −1 g −1 , which is almost 13 times higher than that of CN (Figure 7e). This is due to its porous nanostructure with great surface area, which provides more exposed catalytic active sites along with the prevention of nanosheet aggregation during the HER as shown in the stability of CNB NS for five cycles without any apparent attenuation of the H2 evolution rate. Figure 7f displays the wavelength-dependent apparent quantum efficiency (AQE) of H2 evolution for CNB NS, and the AQE decreases with the increased wavelength due to the light-induced HER, implying enhanced visible light harvesting. In another study, B-doped carbon nitride nanotubes were fabricated by a simple hydrothermal treatment of boric acid and melamine, followed by calcination [117]. Although the band structure of carbon nitride was not changed after B doping, the fully exposed active sites and high-density charge carriers endowed them with a highly efficient and stable hydrogen evolution rate.  Apart from H 2 O 2 , Huang's group introduced ammonium persulphate ((NH 4 ) 2 S 2 O 8 ) into the co-pyrolysis and polycondensation process of g-C 3 N 4 [127]. Owing to its strong oxidative ability, (NH 4 ) 2 S 2 O 8 can inhibit polycondensation from creating nitrogen defects and contribute to the porous structure and oxygen dopants. Importantly, the pathway of electron transition was changed with respect to bulk g-C 3 N 4 , which significantly accelerated the charge separation. As expected, nearly sixfold higher photocatalytic activity than pristine g-C 3 N 4 was observed for O-doped g-C 3 N 4 . Another typical example is that Wu et al. developed multiple thermal treatment methods to obtain hollow O-doped g-C 3 N 4 nanosheets (OCN) under a N 2 /O 2 atmosphere [132]. The formation mechanism was attributed to the adsorption of the O atom in g-C 3 N 4 under the initial thermal treatment of urea in the N 2 /O 2 atmosphere to form OCN-1, which oxidized and allowed integration of more O-doping after being retreated thermally under the N 2 /O 2 to form OCN-2 and then oxidized again to form OCN-3 and OCN-4 ( Figure 8). The same concept could be feasible for allowing the doping of other atoms with O via simple mixing with sources for heteroatoms (i.e., thiourea and boron trichloride). Meanwhile, bulk g-C 3 N 4 (MCN) was synthesized under identical conditions with OCN-1 except for using melamine under an argon atmosphere. The TEM image (Figure 9a) and AFM image (Figure 9b) of OCN-3 showed the formation of porous monolayered nanosheets with uniform distribution of abundant pores (25 nm size) and the thickness of the sheet was~0.45 nm. The surface area, porosity, and O-content increased with increasing the thermal treatment times, but the OCN-3 possessed the highest surface area of (148.50 m 2 /g 1 ) compared to OCN-2 (102.84 m 2 /g 1 ) and OCN-1 (97.88 m 2 /g 1 ); the high surface area of OCN-3 is beneficial for promoting the HER. XPS analysis revealed that the O content increased from 0.84 at% in OCN-1 to 1.62% in OCN-3 and 2.07% in OCN-4. The photocurrent response revealed that OCN-3 had a higher photocurrent density (0.35 µA/cm 2 ) than that of OCN-1 (0.14 µA/cm 2 ) and OCN-2 (0.26 µA/cm 2 ) (Figure 9c) in addition to durability for five cycles over 20 h with only 10.4% loss, but the current density was very low in all samples and the difference between the photocurrent and electrochemical current was inferior. Under visible light irradiation for 5 h, the hydrogen evolution activity of OCN-3 is the highest among these catalysts (Figure 9d). The quantum yield of OCN-3 decreases with increased wavelengths, and it can reach 26.96% at 400 nm and 4.28% at 420 nm (Figure 9e) due to the ability of OCN-3 to induce the generation of electron-hole pairs along with delaying their recombination. This is shown in the electron spin resonance spectroscopy (ESR) analysis with TEMPO, which showed that OCN-3 had a weak signal that is an inaction for a large number of photo-exited electron-hole pairs relative to OCN-1 and OCN-2, implying the significant effect of porous monolayer sheet morphology and higher O-doping (Figure 9f,g). That the signals for electron-hole pairing under light irradiation reduced more slowly over time than its counterparts is evidence of the efficient isolation of photo-exited radicals. Density functional theory was applied to clarify the enhanced photocatalytic mechanism of O atoms. Based on the density of states, the band gap of pure g-C 3 N 4 , O-adsorbed g-C 3 N 4 , and O-doped g-C 3 N 4 is about 2.58, 2.55, 2.16 eV, respectively (Figure 9h-j). Thus, it can be concluded that introducing oxygen atoms can narrow the band gap for harvesting more visible light, promoting the generation and isolation of electron-hole pairs, while porous nanosheets with high surface area provide more accessible active catalytic sites and accelerate the charge mobility and diffusion of reactants or products during the HER. counterparts is evidence of the efficient isolation of photo-exited radicals. Density functional theory was applied to clarify the enhanced photocatalytic mechanism of O atoms. Based on the density of states, the band gap of pure g-C3N4, O-adsorbed g-C3N4, and Odoped g-C3N4 is about 2.58, 2.55, 2.16 eV, respectively (Figure 9h-j). Thus, it can be concluded that introducing oxygen atoms can narrow the band gap for harvesting more visible light, promoting the generation and isolation of electron-hole pairs, while porous nanosheets with high surface area provide more accessible active catalytic sites and accelerate the charge mobility and diffusion of reactants or products during the HER.

Carbon Doping
Li et al. proposed a facile microwave-assisted heating approach to yield C-incorporated g-C3N4 by copolymerizing Π-electron-rich barbituric acid with melamine [135]. Theory calculations showed that carbon incorporation provides more available Π-electrons, shortens the bandgap, and in addition, microwave irradiation could improve the crystallinity of g-C3N4, benefiting the rapid charge transfer. The H2 production amount of Cincorporated g-C3N4 is almost 20 times higher than that of g-C3N4 synthesized by the conventional heating method. Chen and coworkers realized the simultaneous introduction of carbon atoms and nitrogen vacancies in g-C3N4 by a combined hydrothermal-conjugatecopolymerization strategy [136]. Three important features were mentioned: (1) the porous structure could provide more available active sites for reaction species adsorption, (2) the defects-induced midgap could broaden the visible light absorption, (3) the gradient Cdoping could promote charge carrier transfer, enabling excellent photocatalytic activity for C-doped g-C3N4.
Given the unique structural advantage, 1D porous strip-like carbon nitride was prepared by calcining supramolecular precursor (Nic-M) formed by molecular self-assembly of melamine and nicotinic acid (Figure 10a) [138]. The SEM image (Figure 10b) of Nic-CN exhibits a strip nanostructure morphology with about 1 μm width; meanwhile, Nic-M preserved strip-like morphology well (Figure 10c). The TEM image (Figure 10d) shows the thinner strip features of Nic-CN with pores distributed on the surface, which can benefit the photocatalytic reaction. The XPS and elemental analysis confirmed the C-doping

Carbon Doping
Li et al. proposed a facile microwave-assisted heating approach to yield C-incorporated g-C 3 N 4 by copolymerizing Π-electron-rich barbituric acid with melamine [135]. Theory calculations showed that carbon incorporation provides more available Π-electrons, shortens the bandgap, and in addition, microwave irradiation could improve the crystallinity of g-C 3 N 4 , benefiting the rapid charge transfer. The H 2 production amount of C-incorporated g-C 3 N 4 is almost 20 times higher than that of g-C 3 N 4 synthesized by the conventional heating method. Chen and coworkers realized the simultaneous introduction of carbon atoms and nitrogen vacancies in g-C 3 N 4 by a combined hydrothermal-conjugate-copolymerization strategy [136]. Three important features were mentioned: (1) the porous structure could provide more available active sites for reaction species adsorption, (2) the defects-induced midgap could broaden the visible light absorption, (3) the gradient C-doping could promote charge carrier transfer, enabling excellent photocatalytic activity for C-doped g-C 3 N 4 .
Given the unique structural advantage, 1D porous strip-like carbon nitride was prepared by calcining supramolecular precursor (Nic-M) formed by molecular self-assembly of melamine and nicotinic acid (Figure 10a) [138]. The SEM image (Figure 10b) of Nic-CN exhibits a strip nanostructure morphology with about 1 µm width; meanwhile, Nic-M preserved strip-like morphology well (Figure 10c). The TEM image (Figure 10d) shows the thinner strip features of Nic-CN with pores distributed on the surface, which can benefit the photocatalytic reaction. The XPS and elemental analysis confirmed the C-doping as shown by the higher C content in Nic-CN (47.06%) than PCN (45.14%). The UV-vis DRS (Figure 10e) showed the adsorption peak at 200-400 nm with a band edge extended to nearly 460 nm in PCN and 460-700 nm in Nic-CN, due to the 1D porous strip-like morphology and modification of pyridine groups. This led to broadened optical absorption of Nic-CN by a threshold of up to 700 nm more than PCN and enhanced the separation efficiency of photogenerated electron-hole pairs. Moreover, the extended conjugation resulted in a downshift of the conduction band edge and, thus, a narrower bandgap of Nic-CN 2.65 eV than PCN (2.71 eV). Compared with PCN, the lower PL peak intensity of Nic-CN suggests inhibitive recombination and enhanced separation of carriers (Figure 10f). The transient state PL spectra show the shorter lifetime of Nic-CN, which implies the faster transfer of photogenerated charge pairs and efficient separation of charge carriers. Thereby, the photocurrent responses of Nic-CN were higher and quicker than of PCN, implying superior transport (Figure 10g). The photocurrent density of Nic-CN was higher than that of dark current by nearly (1.5 times). Unexpectedly, a nearly 18 times higher hydrogen evolution rate (126.2 µmol h −1 ), was achieved for Nic-CN than that for PCN, due to its porous 1D strip-like shape with high surface area, more exposed and accessible active sites, as well as better optical absorption during the HER. This is shown in the higher surface area of Nic-CN (40.95 m 2 /g) being four times more than PCN. In another report, carbon doping carbon nitride with a hollow tubular structure was fabricated for enhanced photocatalytic performance via a simple hydrothermal calcination method by using melamine and sodium alginate as precursors [139]. Thereby, the photocurrent responses of Nic-CN were higher and quicker than of PCN, implying superior transport (Figure 10g). The photocurrent density of Nic-CN was higher than that of dark current by nearly (1.5 times). Unexpectedly, a nearly 18 times higher hydrogen evolution rate (126.2 μmol h −1 ), was achieved for Nic-CN than that for PCN, due to its porous 1D strip-like shape with high surface area, more exposed and accessible active sites, as well as better optical absorption during the HER. This is shown in the higher surface area of Nic-CN (40.95 m 2 /g) being four times more than PCN. In another report, carbon doping carbon nitride with a hollow tubular structure was fabricated for enhanced photocatalytic performance via a simple hydrothermal calcination method by using melamine and sodium alginate as precursors [139].

Nitrogen Doping
The co-thermal condensation of a precursor with a nitrogen-rich additive is a common way of preparing N-doped g-C 3 N 4 [140,142]. For instance, Fang et al. reported nitrogen self-doped graphitic carbon nitride for the first time by using melamine pretreated with hydrazine hydrate as the starting material [140]. The N/C mass ratio of 1.68 for the typical sample determined by elemental analysis was higher than that of 1.60 for g-C 3 N 4 synthesized with melamine, indicating successful nitrogen incorporation. The as-prepared catalysts yielded nearly 14 times higher H2 evolution activity than pristine g-C3N4. Similarly, Shi's group prepared N-doped porous g-C3N4 nanosheets by calcining urea and N-N dimethylformamide (DMF) [124]. DMF not only affords a N source for N doping but also releases dimethylamine to generate pores in the g-C 3 N 4 framework. Nitrogen-rich carbon nitride nanotubes (CNNTs) were fabricated via the thermal polycondensation of supramolecular intermediates [141]. On one hand, their hollow tubular structure can provide more active sites for light adsorption and more refraction pathways for charge separation. On the other hand, N atoms with larger electronegativity doping could attract more electrons for photogenerated charge carrier transportation.

Halogen Doping
It is well accepted that halogen doping of g-C 3 N 4 can narrow the band gap, expedite the transfer of photogenerated electron-hole pairs, and enlarge specific surface areas, thereby improving its photocatalytic properties [143][144][145][146]. Wen's group proposed a universal route to synthesizing halogen (e.g., Cl, F)-doped g-C 3 N 4 for enhanced photocatalytic hydrogen evolution performance [144]. They found that the F or Cl atom with a higher electronegativity tends to replace the N atom and bond to the C atom. Among them, ultrathin Cl-doped g-C 3 N 4 nanostrips possess the strongest light absorption, a narrow band gap, larger specific surface areas, and faster charge separation and migration, thus delivering an excellent H 2 evolution rate of 5976 µmol h −1 g −1 . Gao et al. studied carbon nitride's iodine surface modification and doping by heating the self-assembly precursors formed by urea and ammonium iodide [145]. As an electron donor, iodine doping could increase the electron density in carbon nitride networks and tune their band structure. Moreover, the surface iodine could bond with positively charged holes to hinder the recombination of photogenerated charge pairs.
Cui et al. prepared B-and F-co-doped g-C 3 N 4 via thermal polymerization of dicyandiamide, urea, and ionic tetrafluoroborate liquids, followed by post-annealing treatment [150]. The B atoms mainly located in the inside skeleton of g-C 3 N 4 , whereas F atoms existed in the surface layer. It was found that inner B doping contributes to enhancing visible light absorption and generating uniform porous structures during post-calcination treatment. Afterward, the same group reported the synthesis of porous C-I-co-doped carbon nitride with a similar method except for using an iodized ionic liquid as a precursor [153]. In another study, boron/oxygen-co-doped g-C 3 N 4 nanomesh was obtained by a two-step doping and etching approach [151]. The as-prepared sample possessed a two-dimensional porous structure with a specific surface area of 160.58 m 2 g −1 .
Moreover, doped B and O atoms can regulate the band gap. Owing to the synergistic effect of the nanomesh-like structure and B-and O-co-doping, the light absorption ability and charge separation efficiency of g-C 3 N 4 were enhanced. As a result, they displayed an excellent H 2 evolution rate of 9751 µmol h −1 g −1 under visible light illumination, which is almost 28 times higher than bulk g-C 3 N 4 . More importantly, the H 2 evolution activity kept over 20 h, revealing its robust stability. Dai's group proposed a facile approach to prepare C-and P-co-doped g-C 3 N 4 (CPCN-1*) by the first self-assembly of melamine with phytic acid (denoted as CPCN-1), followed by hydrothermal treatment [154]. For comparison, pristine g-C 3 N 4 (CN) was synthesized under identical conditions with CPCN-1 other than phytic acid, and CN* was obtained after hydrothermal treatment of CN. The SEM image of CPCN-1*, showed the formation of porous granular morphology (Figure 11a) with a rough surface and curled edges ( Figure 11b); meanwhile, element mapping analysis revealed the presence of C, N, O, and P (Figure 11c-f). The surface area CPCN-1* (141.1 m 2 /g) was significantly higher than that of CN (24.9 m 2 /g) CN* (75.7 m 2 /g) and CPCN-1 (44.8 m 2 /g), due to the porous morphology and co-doping effect. Apparently, C and P doping could not change the band gap significantly but decreased the conduction band position of CPCN-1 and CPCN-1* in comparison with that of CN and CN*, implying much-enhanced photo-reducibility after co-doping (Figure 11g). Thus, CPCN-1 and CPCN-1* allowed for efficient improvement in the transfer of photogenerated electron-hole pairs over undoped CN and CN* because the dopants acted as trapping sites to restrain the combination of charge carriers. XPS analysis showed that the content of P dopants was found to be 0.29% in CPCN-1 compared to 0.14% in CPCN-1*. The H 2 production rate on CPCN-1* (1493.3 µmol h −1 g −1 ) was 2.24, 2.34, and 9.7 times that of CPCN-1 (663.7 µmol h −1 g −1 ), CN* (637.6 µmol h −1 g −1 ), and CN (153.9 µmol h −1 g −1 ), respectively (Figure 11h). This implies porous morphology with a higher surface area and co-doping lead to high optical adsorption, efficient charge transport, and great photoinduced reducibility. Moreover, CPCN-1* showed high stability over four cycles for 13 h. The photocurrent responses over five on-off cycles revealed the obvious enhancement in the current density under light than under dark with reversible behavior and the photocurrent intensity remained stable during the five cycles, but CPCN-1* was the most active (nearly eight times CN) (Figure 11i). Beyond the above observation, the integration of binary heteroatom-doping and a heterojunction structure into g-C 3 N 4 was also realized for enhanced photocatalytic performance [155,160].

Ternary Heteroatom-Doped Porous Carbon Nitride
It has been proven that ternary heteroatom doping can show higher photocatalytic activity and unusual physiochemical properties with respect to binary and single heteroatom doping. For instance, Liu and coworkers realized the simultaneous doping and exfoliation of g-C 3 N 4 by fabricating S-, P-, and O-co-doped ultrathin nanosheets via a facile annealing method [161]. As displayed in Figure 12a, S-and P-co-doped g-C 3 N 4 (denoted as CN-SP) was first obtained by thermal condensation of the mixed precursors of melamine, thiourea, and diammonium phosphate. Subsequently, the CN-SP was annealed in the air for O doping; meanwhile, it could be exfoliated into ultrathin nanosheets (denoted as CN-SPO). The TEM image of CN-SPO ultrathin (~3 nm) exfoliated nanosheets morphology with sharp edges flat surface (Figure 12b), while CN and CN-SP had thicker tightly stacked sheets. The EDX analysis of CN-SPO clearly warranted the coherent distribution of C, N, S, P, and O, but the exact content is not mentioned in the manuscript (Figure 12c-g). Moreover, the XPS analysis of CN-SPO displayed the presence of C, N, S, P, and O. Experimental and theoretical results demonstrated that the S atoms occurred on the interstitial sites, whereas P and O atoms substituted C and N atoms, respectively. S, P, and O doping can probably create a more favorable charge transfer channel and boost charge migration. Accordingly, CN-SPO displayed the highest photocurrent response (8 µA/cm 2 ), compared to CN-SP and CN, implying the significant effect of S/P/O doping on the optimal separation rate of photogenerated carriers under visible light irradiation (Figure 12h). This is seen in the ESR analyses, which displayed a lower TEMPO-eand TEMPO-h + TEMPO with three peaks (with ratio of 1/1/1) but with a less intensity on CN-SPO than CN under light than under dark (Figure 12i,j). This implied the superior reactivity of photoinduced charge carriers on CN-SPO. In addition, the narrow band gap and negatively shifting conduction band edge caused by heteroatom doping could broaden visible light absorption and enhance electron reducibility. As a result, an optimal H 2 evolution rate of (2480 µmol g −1 h −1 ) was observed for CN-SPO, which was superior to CN (465 µmol g −1 h −1 ) by five times. This is due to the tri-dopant, which promoted the photoexcited electrons transfer through the (O-P-C-N 2 -S-N 2 or N 2 -S-N 2 -C 1 -P-O) chain among the two adjacent heptazine units, which eased the isolation of the photogenerated carriers.

Conclusions and Prospective
This review highlighted the synthesis of non-metal-doped porous gCNs for the photocatalytic HER. This includes the utilization of H2 as a fuel and its storage in addition to the fundamentals related to water electrolysis and the photocatalytic HER process (i.e., mechanism, measurements, and calculation) and non-metal dopant configuration into (h) transient photocurrent responses on 5%-NPOC@CN relative to its counterparts. Adapted with permission from Ref. [162]. 2022, Elsevier Inc.

Conclusions and Prospective
This review highlighted the synthesis of non-metal-doped porous gCNs for the photocatalytic HER. This includes the utilization of H 2 as a fuel and its storage in addition to the fundamentals related to water electrolysis and the photocatalytic HER process (i.e., mechanism, measurements, and calculation) and non-metal dopant configuration into gCNs. Meanwhile, the effect of non-metal dopants (i.e., mono, binary, and ternary heteroatom (i.e., P, O, S, N, and B)-doped porous gCN nanostructures on the enhancement of photocatalytic H 2 production were also discussed as a function of photocatalyst shape, composition, bandgap, and electrolyte type or concentration on HER activity and durability.
Mono-non-metal-doped porous gCNs are studied more than binary-doped, while ternary-doped gCN is rarely reported; however, mono-doped gCNs are the most active and promising for the HER. B-CNNT obtained via the hydrothermal and calcination of method in the presence of boric acid revealed a H 2 rate of (22,100 µmol h −1 g −1 ) [117] relative to CNNTs formed via the supermolecule self-assembly method that showed a H 2 rate of (18,060 µmol h −1 g −1 ) [141], and PCNNFs fragmented nanoflakes obtained via doping and annealing of biomass (15,921 µmol h −1 g −1 ) [95]. Binary BO-C 3 N 4 formed via a two-step doping and etching method is among the most promising photocatalysts for HERs, with a H 2 evolution rate of (9751 µmol h −1 g −1 ) [151] in addition to high durability for 20 h. Moreover, p-CN-BF obtained via in situ co-doping using [Emin]BF 4 and calcination in air yielded a H 2 rate of (7020 h −1 g −1 ) [150]; however, both materials needed Pt as a co-catalyst. Ternary CN-SPO showed a H 2 evolution rate of (2480 µmol g −1 h −1 ) [161] due to the presence of S atoms on the interstitial sites and substitution of C with P and N atoms with O atoms in gCN, resulting in lower bandgap and higher light absorption efficiency. The supramolecular self-assembly of multiple nitrogen-enriched carbon precursors such as melamine with cyanuric acid [105] and urea with ammonium iodide [145] are effective in the formation of porous gCN nanostructures with high surface area. This is in addition to facilitate in situ doping with non-metal atoms during the self-assembly process (i.e., S-doping in case of self-assembly of thiourea, O doping using cyanuric acid, and B doping using boric acid). Although there has been substantial progress made in the synthesis of porous, doped gCN photocatalysts for HERs, they remained impractical for large-scale applications and various perspectives and barriers are still unaddressed:

•
Previous porous, doped gCNs in the form of 2D nanosheets and other porous nanostructures are rarely reported or not yet reported. Porous multidimensional doped gCN (i.e., nanoflower, nanodendrite, yolk-shell, and nanocage) and one-dimensional (i.e., nanowires, nanotubes, nanorods, and nanotubes) morphologies are imminent with their impressive characteristics (i.e., high electrical conductivity, great surface area, abundant defects, massive active/accessible active sites, stabilization of metal/nonmetal atoms, and maximized atomic utilization) [163]. These merits can endow the HER activity and the durability of doped porous gCNs. Such porous nanostructures could be synthesized using multiple nitrogen-rich carbon precursors containing non-metal elements (i.e., melamine, thiourea, cyanuric acid, and cyanimide) and changing the preparation conditions (i.e., annealing environment, templates, and solvent type) [28,163]. Meanwhile, the reported g-doped porous gCNs are powder, which cannot be used directly in electrolysis and require several steps to be used as a cathode. This could be realized via the in situ fabrication of gCNs on solid carbon-cloth sheets or metal hydroxide/oxide substrate that could be used as a cathode for the HER. • Particular attention should be paid to developing facile, one-step, and eco-friendly methods to fabricate g-C 3 N 4 with various morphologies. Recently, our group developed a simple, template-free, one-pot approach for the fabrication of porous onedimensional gCN nanostructures (i.e., wires, fibers, tubes, and rods) in situ, doped with various metals (i.e., Au, Pd, Pt, Cu, and their combinations) with high surface area and outstanding catalytic properties for CO oxidation [3][4][5]164]. The same tactics can be extended to prepare other gCN structures with various single-atom metals, dopants, and nanoparticles for CO 2 reduction. Single-atom-impeded g-C 3 N 4 for CO 2 reduction is not studied enough. g-C 3 N 4 comprises a triazine or heptazine skeleton that can accommodate various single-metal atoms to maximize atom utilization; minimize attrition; reduce deactivation; and enhance CO 2 activity, selectivity, and durability. • Both experimental and theoretical calculations/simulations (i.e., DFT and artificial intelligence) could be coupled to understand the effect of non-metal dopants on the physicochemical properties of porous gCN nanostructures and their catalytic/ photocatalytic activities and mechanisms.

•
The relatively high overpotential, low current densities, and inferior long-term stability are critical barriers in gCNs for HERs, which cannot meet practical requirements (i.e., current density up to several ambers and durability for several weeks or months). This could be solved using noble metal dopants in the formation of heterojunction structures with porous metal oxynitride [165,166], multimetallic nanocrystals [12,167,168], MXenes [2,[169][170][171][172], MOF [10,173,174], graphene [175], and graphdiyne [176] to augment solar light harvesting and charge carrier separation during the HER.

•
The safety of H 2 storage tanks should be considered because in the case of unexpected accidents, the H 2 tank becomes a bomb. Defeating these barriers requires using highpressure vessels made of fiber-based composites that can afford a high pressure of up to 700 bar and subsequently can improve cold or cryo-compressed hydrogen storage along with boosting H 2 density and using novel, durable, low-cost materials for H 2 adsorption [18,[46][47][48]. Moreover, using novel adsorbents for H 2 storage is safer than tanks, but needs more efforts to decrease operation conditions (i.e., pressure) and enhance storage capacity.
Author Contributions: All authors contributed equally to this work. Data collection, methodology, and writing-original draft preparation (Q.L., A.A. and J.L.); conceptualization, revision and supervision and project administration (K.E.

Data Availability Statement:
The data presented in this study are available on request from the corresponding authors.