Open Access Article
Gbemi F. Abass†
a,
Adnan Ahmad†
bc,
Cheng Yangbc,
Yun Liu
*bc and
Terry J. Frankcombe*a
aSchool of Science, The University of New South Wales, Canberra, ACT 2612, Australia. E-mail: t.frankcombe@unsw.edu.au
bResearch School of Chemistry, The Australian National University, Canberra, ACT 2601, Australia. E-mail: yun.liu@anu.edu.au
cARC Centre of Excellence for Carbon Science and Innovation, Australia
First published on 25th March 2026
Among emerging photocatalysts, graphitic carbon nitride (g-C3N4) has attracted considerable attention as a metal-free, visible-light-active semiconductor for sustainable hydrogen production and environmental remediations. Here we demonstrate that many of the obvious models for the layer structure and preferred stacking arrangements of g-C3N4 lead to incorrect predictions of photocatalytic properties. We present a systematic structural exploration of monolayer and bulk geometries of heptazine-based g-C3N4 using first principles density functional theory (DFT) to assess their stability and elucidate how these configurations influence their electronic properties. Across all systems investigated, we show that using a buckled heptazine structure—rather than the conventional planar geometry—represents the true energetic ground-state structure. A buckled structure is also found by reverse Monte Carlo analysis of experimental data, also reported here. Further analysis of buckling and different stacking registries in g-C3N4 layered structures reveals newly identified low-energy corrugated stackings (with P1 symmetry) that give rise to a broad range of electronic band gaps, several of which closely match experimentally reported values of ∼2.7 eV. Moreover, introducing non-metal P and metal Ni dopants at identical lattice sites across 2D-planar/buckled and 3D-corrugated hosts shows distinct electronic responses. Our findings demonstrate that accurate structural modelling, including buckling and stacking registry, is crucial for reliably capturing the stability and tunable electronic properties of g-C3N4.
Graphitic carbon nitride exists in two structural frameworks, comprising either s-triazine (C3N3) units or tri-s-triazine (C6N7, also known as heptazine) units. Both structures consist of fused 6-membered rings with sp2 hybridized C and N atoms, forming delocalized π-conjugated polymeric networks. Moreover, as revealed by X-ray diffraction (XRD), g-C3N4 is a hexagonal layered structure with two characteristic peaks at 2θ of approximately 13.04° and 27.6°, attributed to the 〈10
0〉 in-plane periodicity and 〈0002〉 interlayer stacking governed by weak van der Waals interactions, respectively. While s-triazine and heptazine share a layered graphitic arrangement, heptazine units, consisting of three fused triazine rings, are energetically more favourable.6–8 Zhang et al.9 report the structural evolution from triazine to heptazine during thermal polymerization and highlights new theoretical insights for synthesizing heptazine-based g-C3N4 at lower temperatures.
Unlike graphene, which consists mainly of carbon atoms, polymeric g-C3N4 contains both carbon and nitrogen atoms, resulting in increased structural complexity. Consequently, uncertainty regarding the precise structure of polymeric g-C3N4 and the identification of its true ground-state structure continues to present significant challenges for both experimental and theoretical investigations. For example, the conventional synthesis route of polymeric carbon nitride, such as thermal polycondensation in air, typically yields a semicrystalline structure with mixed motifs, thereby complicating precise structural characterization.10 The reduced crystallinity of g-C3N4 is commonly attributed to incomplete polymerization and the persistence of hydrogen bonding within the synthesized sample, which results in a partially condensed framework of a melon-type g-C3N4 structure.11
Recently, Negro et al.10 conducted a combined experimental and theoretical investigation on g-C3N4 structure using different characterization techniques such as XRD, FTIR, SEM, UV-Vis, and data from density functional theory (DFT) tools. Their study demonstrated that thermal polymerization of melamine produces a mixture of structural motifs comprising less-condensed melon frameworks together with highly condensed g-C3N4 domains. Another study by Zhang et al.12 provides insights into the structural transformation mechanism of g-C3N4 synthesized via a molten salt-assisted procedure. They report a sequential phase evolution in which melon converts first into poly(heptazine imide) as an intermediate phase, and subsequently into poly(triazine imide) as the more stable phase. Collectively, earlier works have demonstrated that the structure, and consequently the properties, of g-C3N4 can be modulated via different synthesis routes such as precursor composition, condensation temperature, reaction rates and related factors.9,13 Nonetheless, the fundamental question of what is the ground state structure of fully polymerized heptazine-based g-C3N4 has not been answered through experimental investigation.
In an effort to resolve the true ground state of pure heptazine-based g-C3N4, numerous theoretical investigations based on DFT and molecular dynamics have been conducted.14–16 While numerous studies employ a graphene-like planar model of P
m2 symmetry for the g-C3N4 layer structure, other studies have allowed the geometry to flex into nonplanar structures. Recent theoretical work11,17,18 has demonstrated that out-of-plane structures, such as buckled or corrugated layers, are energetically more favourable and offer a more realistic model of the fully polymerized heptazine phase. Moreover, Zhao et al.19 proposed three corrugated structures of P321, P3m1 and Pca21 symmetry for experimentally sythesized g-C3N4. These were found to be energicatlly more stable than the conventional flat P
m2 model. Other theoretical investigations that adopted a flat g-C3N4 model as the initial structure for adsorption or dopant studies consistently yielded buckled configurations, with planarity not being preserved once the symmetry is broken in the calculation.20–23 These observations collectively suggest that out-of-plane buckling is an intrinsic feature of g-C3N4. However, it remains challenging, experimentally, to detect the subtly buckled heptazine phase. When the basal plane of the layered structure is viewed from above (with atomic-resolution microscopy techniques) the corrugated and planar g-C3N4 structures would be virtually indistinguishable.
Another important consideration in the search for the true ground state of heptazine-based g-C3N4 requires careful evaluation of how the two-dimensional (2D) layers are arranged to form a stacked three-dimensional (3D) bulk structure. The different stacking configurations between adjacent g-C3N4 sheets play a decisive role in determining the structural stability and electronic properties of the bulk phase. Although many theoretical studies24–26 have modelled exfoliated g-C3N4 as an isolated monolayer to rationalize enhanced photocatalytic activity, the persistence of the (0002) diffraction peak indicates evidence of residual interlayer stacking. As a result, interlayer interactions and π–π overlap between adjacent sheets must not be neglected in describing the ideal phase of heptazine-based g-C3N4. In 2018, Sun et al.27 investigated the electronic properties of graphitic carbon nitride with different building blocks and staggered between sheets in the bulk phase. In their study, triazine- and heptazine-based structures were examined under different stacking configurations (P
m2, R3m, Cmcm, and P63/mmc), and the results showed that bulk g-C3N4 polymorphs exhibit narrower band gaps than the corresponding monolayers, with the reduction attributed to interlayer band overlap between adjacent CN sheets. Other previous studies have also indicated that polymeric carbon nitride comprises stacked layers that preferentially adopt AB stacking registries as compared to AA.18,28 However, the precise stacking order and local structural motifs remain uncertain due to experimental constraints, motivating further investigation.
A more recent study29 demonstrated that the electronic and optical responses of polymeric g-C3N4 are dependent on the microstructural features, particularly the degree of condensation, out-of-plane corrugation, and interlayer interactions. These conclusions are consistent with prior work,10,11 providing a strong rationale to systematically investigate the effect of buckling and stacking configurations in developing a more robust theoretical model for the fully condensed heptazine phase of g-C3N4.
Mridha et al.30 recently advanced the earlier work of Im and colleagues29 by providing a dynamic analysis of the ground-state structure of g-C3N4, systematically examining heptazine-, h-triazine-, and o-triazine-based polymorphs in both bulk and monolayer models. Their phonon calculations revealed that all planar polymorphs are dynamically unstable and relax to buckled structures, with heptazine identified as the energetically preferred structure.
While earlier studies have confirmed that buckling is intrinsic to the stability of g-C3N4, their scope remained limited to idealized monolayers and bulk phases, without assessing the influence of stacking registries on the relative stability of corrugated heptazine structures. To address this gap, the present study systematically investigates the interplay between buckling and different stacking configurations in heptazine-based g-C3N4, with a direct comparison between planar/buckled monolayers and the energetically preferred corrugated bulk phase. In addition, we have investigated how altering the assumed buckling and stacking structure affects the properties of phosphorus and nickel doping of g-C3N4. Our results reveal that the combination of buckling and appropriate stacking configurations stabilizes heptazine by yielding lower-energy corrugated structures.
Exchange–correlation energies were treated within the generalized gradient approximation (GGA) using the Perdew–Burke–Ernzerhof (PBE) functional. To properly account for weak interlayer interactions in the bulk models, van der Waals corrections were included using the DFT-D3 scheme33 with Becke–Johnson damping. The PBE functional without dispersion corrections as well as the r2SCAN meta-GGA and HSE06 screened hybrid functionals were used for specific comparisons, as noted in the results presented below. These functionals were applied at the geometries that minimize the PBE-D3(BJ) energy. To assess the robustness of the predicted structure, one representative bulk structure was also fully optimized using different functionals (see Table S3 and Fig. S3). The plane wave energy cutoff was set as 500 eV, while the self-consistency energy convergence criterion was set to 10−6 eV. All structures were based on layers comprised of 2 × 2 supercells of the heptazine monomeric unit and an accompanying pore. The Brillouin zone was sampled using Γ-centered k-point meshes, specifically a 3 × 3 × 1 grid for 2D structures (incorporating a nominally 20 Å gap between layers) and a 3 × 3 × 7 grid for the 3D bulk systems. These grid point meshes were selected based on convergence tests that confirmed they are well-converged with respect to total energy (see Fig. S1).
To systematically search for lower-energy configurations, we introduced out-of-plane shifts of 0.5 Å for different atoms within heptazine to break the planar symmetry as depicted in Fig. 1. The monolayer was partitioned into four symmetry-related regions labelled a, b, c, and d. Each label corresponds to two pyridinic nitrogen atoms (N2C sites), which are two-coordinated nitrogen atoms bonded to two carbon atoms within each heptazine unit. These N2C atoms serve as the primary sites where out-of-plane perturbations were applied to initiate buckling. Model 1 represents the planar reference structure without any atomic perturbation, whereas models 2 to 5 incorporate systematic clockwise (+) and anti-clockwise (−) out-of-plane atomic shifts.
![]() | ||
| Fig. 1 Exploration of low-energy g-C3N4 buckling patterns initiated by atomic shifts/distortions of the planar monolayer. | ||
To determine the stability of P and Ni dopants in the 2D/3D g-C3N4 structures, we carried out spin-polarized DFT calculations. The energy required to create a substitutional defect (Esubform) and an interstitial defect (Eintform) were calculated using the following formation energy equations:
| Esubform = Edoped − Eundoped − μdopant + μC/N | (1) |
| Eintform = Edoped − Eundoped − μdopant | (2) |
The interlayer binding energy was calculated using the expression:34,35
![]() | (3) |
A limited investigation of molecular heptazine dimers was conducted using the Gaussian 16 code.36 Two heptazine molecules (C6N7H3) were brought together edge to edge in a constrained relaxation, controlling the N–N distance of one intermolecular pair and maintaining the planes of the two molecules at right angles to emphasise the N–N lone pair interaction. The MP2/def2-SVP level of theory was used for dimer calculations. Moreover, limited reverse Monte Carlo (RMC) simulations were performed on X-ray total scattering data from synthesised samples of g-C3N4.37 These simulations were performed with the RMCProfile code.38–40 Starting from a 10
000 atom supercell of planar bulk g-C3N4, the RMC iteratively perturbs the positions of these atoms until the calculated scattering pattern matches the experimentally measured data.
Note that the energy difference between our model 4 and the flat model 1 is significantly larger than the differences found between the structures investigated by Mridha et al.30 The periodicity of the single heptazine cell used by this earlier work limits the structures that can be found by their phonon-following approach to be of our model 2 type (cf. Fig. 1).
The shortening of the bridging C–N bonds upon buckling suggests buckling relieves steric hinderance between lone pairs of non-bonded nitrogens on the heptazine edges. This was investigated briefly by examining the potential energy profile of two heptazine molecules (C6N7H3) brought together edge to edge in a constrained relaxation, controlling the nearest intermolecular N–N distance. Increasing the N–N distance from the 2.4 Å found in the flat structure to the 2.7 Å of the buckled geometry decreased the total energy by 0.43 eV at the MP2/def2-SVP level. As there are twelve such “intermolecular” N–N pairs in heptazine g-C3N4, this represents a significant reduction in energy through relief of these clashing electron-rich atoms. Although there will be some contribution from different levels of theory [MP2 versus DFT with PBE-D3(BJ)], that the total reduction of energy upon buckling is significantly less than 12 × 0.43 eV suggests that strain within the structure on buckling limits the distortion.
Our model 4 structure exhibits antiphase distortions (i.e. alternating distortion directions) along the 〈10
0〉 and 〈01
0〉 directions. This suggests energetic coupling between distortions similar to antiferroelectric coupling in ionic crystals. Such an interpretation would make the distortions frustrated on the hexagonal lattice of g-C3N4, as the symmetry-equivalent 〈
100〉 direction cannot simultaneously exhibit antiphase ordering in this finite 2 × 2 instantiation of the structure. Thus one may expect significant dynamical fluctuations of the out-of-plane distortion structure in real g-C3N4 crystals.
Our findings further support earlier reports44,45 that corrugated structures resemble the flat g-C3N4 model (Fig. 2) when viewed from above the basal plane, which led to the widely used flat (metastable) P
m2 model in previous theoretical studies to interpret experimental data. However, having established the buckled configuration as the true energy minimum for the single-layer heptazine model, we proceed to examine the interlayer interactions and stacking registries of these corrugated sheets. The motivation to extend this structural investigation arises from experimental observations showing that exfoliated g-C3N4 nanosheets often retain interlayer spacings corresponding to the (0002) reflection in X-ray diffraction patterns. Moreover, while the precise interlayer registry of heptazine-based g-C3N4 remains unresolved, the stacking configuration cannot be neglected when accurately describing the synthesized heptazine sample. Therefore, in the following section, we systematically explore different stacking possibilities of heptazine-based g-C3N4 using first-principles theoretical calculations.
A series of initial configurations was tested to search for the most favourable interlayer configurations. In all cases we use a supercell comprising two layers of g-C3N4 sheets, yielding 2 × 2 supercells of the heptazine monomer. These are illustrated in Fig. 3.
The bulk material with no lateral shift between each layer is denoted AA stacking. A range of AB-type stacking patterns were generated for testing. Those we label AB1, AB2 and AB3 were generated by introducing an initial lateral shift of 0.6 Å along the a, −b or −2b − a directions, respectively, from the AA structure for every other layer. Another set of 180°-rotated AB variants was modelled, in which one flat or corrugated layer was first rotated by 180° relative to the perfectly aligned AA stacking. In this arrangement, the carbon atoms lie within the void regions, while only some nitrogen atoms, including the bridging nitrogen atoms (not carbon), overlap. As seen in Fig. 3, AB* is used to denote the structure resulting solely from this rotation, a structure that is usually denoted simply AB in other work. We also consider applying similar lateral shifts to those described above from this AB* structure, denoted
,
and
. This notation was extended with an additional subscript f or c to distinguish between structures constructed from flat or corrugated g-C3N4 layers, respectively. For example,
is a staggered model comprising corrugated layers of alternating orientation that has been initially shifted along the b axis.‡ All structures were relaxed with the PBE-D3(BJ) functional.
The optimized lattice parameters, lattice angles, and relative energies [computed using various exchange–correlation (XC) functionals] for each configuration are presented in Table 1. Consistent with previous theoretical studies,27,28 the flat AAf reference model (with lattice constants a = 14.2 Å and c = 6.73 Å) was the highest energy structure. However, introducing a 180° rotation in the flat ABf stacking motif, denoted as
, lowers the energy by ∼3.1–4.0 eV across all the XC functionals, highlighting that changes in the stacking registry can significantly influence structural stability. In contrast, the corrugated AAc structure undergoes an in-plane contraction (a = 13.9 Å) and a slight expansion along c (∼ 7.18 Å) and lowers the energy by ∼6.6 eV. The enhanced stability of the AAc stacking configuration, relative to the previously discussed models, can be attributed to the relief of interlayer electrostatic repulsion through out-of-plane buckling.
Modifying the interlayer arrangement in the corrugated bulk structure results in a further reduction in total energy, with the AB3c registry attaining the lowest relative energy (−7.81 eV at the HSE level) within this stacking series. Moreover, among the 180°-rotated corrugated stacking series,
shows moderate stability, whereas the addition of translational shifts in
achieves the lowest energy stacking configuration across all the XC functionals. Consistent with these structural relaxations, the corrugated stacking registries exhibit buckling heights ranging from ∼0.97 to 2.84 Å, including 1.28 Å for AAc and 0.97 Å for
, while the AB1c–AB3c motifs show distortions of ∼1.31–1.42 Å, reaching up to 2.84 Å for
.
To further investigate the interlayer coupling strength of the various stacking registries in g-C3N4 the interlayer binding energy is considered. This provides a quantitative measure of the cohesion between adjacent heptazine sheets.
The interlayer binding energy is calculated using eqn (3). Table S2 provides details of the interlayer binding energies for all planar and corrugated stacking registries. Across these configurations, the binding energy values fall within 6–17 meV Å−2, lower than the binding/exfoliation energies of some other van der Waals materials such as graphene (22.5 meV Å−2)48 and MoS2 (26.3 meV Å−2).34 This shows that all g-C3N4 stacking registries considered here are weakly bound and readily exfoliable, yet the relative differences among them remain significant. For example, the AAf registry exhibits the lowest interlayer binding, while the
configuration shows the highest binding energy, indicating a more favorable alignment that enhances structural stability. This trend highlights that even minor registry shifts or corrugation patterns can modulate the weak van der Waals interactions between adjacent heptazine layers.
Overall, the results of our theoretical investigation show the profound influence of the synergistic effect of corrugation and stacking registry on determining the true ground state of layered heptazine-based g-C3N4. The emergence of these newly identified corrugated stacking configurations (all exhibiting P1 symmetry) provides a robust structural framework for systematically investigating how stacking transitions through, for example, applying mechanical shear, can modulate the electronic properties of bulk g-C3N4, as will be discussed in the next section.
Fig. 4 also shows the corresponding PDOS of both planar and buckled configurations, revealing the contributions of each atomic orbital type to the electronic band. In the valence band (VB), the major contribution originates mainly from the N-2p lone-pair orbital, while the conduction band (CB) is composed of the hybridization of C-2p and N-2p states. Moreover, both the band structure and PDOS of the buckled monolayer reveal an upward shift of the conduction-band edge compared to the planar model, resulting in a larger band gap (although we note that the Fermi energy is not defined meaningfully in calculations of this type). Our observations are in good agreement with previous reports.45,52,53
We now shift our attention to examining how different stacking motifs of the heptazine units influence the electronic properties of bulk g-C3N4. The layered structure of 3D–g-C3N4 introduces additional band dispersion along the out-of-plane direction, resulting in a narrower band gap compared to the isolated monolayer. For example, comparing the band structure plots in Fig. 4 and 5, all the bulk stacking configurations exhibit smaller band gaps than the monolayer. For the flat models (at the PBE level), the band gap decreases from 1.25 eV in the monolayer to 0.59 eV (AAf) and 1.03 eV
, and from 2.82 eV to 1.93 eV (AAf) and 2.06 eV
at the HSE06 level. A similar trend is also observed for buckled models, where the corresponding band gaps reduce from 1.87 eV in the monolayer to 1.59 eV (AAc) and 1.60 eV
at the PBE level, and from 2.97 eV to 2.66 eV (AAc) and 2.65 eV
using the HSE06 hybrid functional.
Next, we extend our analysis to compare how different stacking arrangements (in the flat and corrugated models) influence the electronic response of bulk g-C3N4. It can be seen from Fig. 5a–d and S2 that introducing a 180° rotation in the AA stacking registry, together with the presence of buckling in either stacking configuration, modulates the bulk electronic properties. While rotating the flat AA stacking motif moderately widens the band gap from 1.93 eV to 2.06 eV (HSE06), the introduction of buckling in the AA stacking (denoted as AAc), even without rotation, results in a wider band gap of 2.66 eV (HSE06), which is in close agreement with experimental observations (2.7 eV).54 Moreover, applying a 180° rotation to the buckled AA stacking
induces minimal changes in the band gap, indicating that structural buckling exerts a more dominant role in determining interlayer electronic coupling compared with rotational misalignment alone. These findings suggest that lateral translation or combined rotation-translation of the layers, for example by applying shear stress to the material, could serve as a viable strategy to tune the bulk electronic properties of van der Waals layered g-C3N4. As shown in Fig. S2, the electronic response of the different corrugated stackings modulates the band dispersion and PDOS of bulk g-C3N4.
A more detailed comparative analysis of the band gaps in Fig. 6 quantifies the effect of these corrugated stacking variants. Relative to the unshifted corrugated models (i.e. AAc,
), lateral translation increases the band gap by about 6%. In contrast, the combined rotation–translation raises it by roughly 15%, with the most stable structure,
, exhibiting the widest band gap (3.05 eV) in these stacking series. Our findings reveal that while stacking of flat layers reduces the band gap, corrugation of stacked layers both enhances the thermodynamic stability and yields larger band gaps, consistent with the postulation of Im et al.11 Accordingly, one may speculate that the band gap modulation approach demonstrated in this work may be extended to other two-dimensional materials to control their electronic properties, possibly including charge transport and photoresponse characteristics.
The P@C6 site was used as a model defect to examine how dopant accommodation varies with buckling and stacking structure, comparing the 2D-planar and buckled monolayers with the buckled 3D-stacked g-C3N4. Fig. 7 shows that the formation energy changes dramatically from the planar sheet (1.64 eV) to the buckled monolayer (0.19 eV), whereas the 3D-buckled structure exhibits an intermediate stability (0.67 eV). The variation in formation energies, despite using the same dopant sites (P@C6) across all structures, indicates that each host lattice accommodates the dopant differently. In the planar monolayer (Fig. 7a), the P dopant is constrained by the in-plane symmetry of the lattice, resulting in a P–N bond length of 1.59 Å, longer than the intrinsic C–N bond length of 1.33 Å, giving rise to local strain. In contrast, the buckled monolayer alleviates this strain by allowing the dopant to relax out of plane, as reflected by the P–N bond length (1.63–1.64 Å, Fig. 7b). In the 3D-buckled structure (Fig. 7c), the local bonding geometry around the P dopant is nearly identical to that of the buckled monolayer, with comparable P–N distances. However, the difference in the formation energies between the 2D buckled monolayer and the 3D buckled lattice can be attributed to the long-range interlayer interactions in the bulk and not from the local bonding environment. Similarly for the Ni dopant at the same interstitial sites across the planar, buckled monolayer, and 3D-buckled structures (Fig. 7d–f), the formation energies vary with 1.63 eV for planar 2D, 1.72 eV for buckled 2D, and 1.35 eV for buckled 3D. The variation in dopant energetics between P and Ni at identical sites across flat, buckled, and layered g-C3N4 structures demonstrates that accurate theoretical modelling of g-C3N4 must account for intrinsic structural stability as well as the influence of interlayer coupling.
The buckling and stacking structure influenced the effect of dopants on the calculated electronic structure. Fig. 8a–c and S8a–c show that doping with P does not significantly alter the bulk band structure of the underlying g-C3N4 structure. The significant change to the electronic structure is the introduction of mid-gap states associated with the P dopant atom. For the neutral systems modelled here, a single electron occupies one of these states, with the opposite spin state remaining unoccupied. Clearly, such mid-gap states could be expected to have a significant effect on the photocatalytic properties of doped g-C3N4.
![]() | ||
| Fig. 8 Spin-polarized projected density of states (PDOS) of P- and Ni-doped g-C3N4; (a–c) P-doped and (d–f) Ni-doped systems across 2D planar, 2D buckled, and 3D buckled configurations. | ||
The position of these states within the gap, and the separation between the occupied and unoccupied states, are strongly affected by the modelled structure. The planar 2D structure yields a small separation between the occupied and unoccupied states, with both lying close to the conduction band of g-C3N4. Allowing the monolayer to buckle out of the plane separates the occupied and unoccupied states by around 1 eV, with the occupied state lying close to the valence band. Stacking g-C3N4 into a bulk structure causes both mid gap states to move higher in the band gap.
Charge density difference (CDD) and Bader charge transfer calculations for these P-doped structures are represented in Fig. 9a–c. These again demonstrate significant differences between the different g-C3N4 parent structures, with significant differences between the amount of charge transferred to the g-C3N4 structure depending on whether the doped parent is planar, buckled, or in bulk.
For g-C3N4 doped with interstitial Ni, the parent band structure was again largely unchanged from the undoped material's band structure for the monolayer cases (Fig. 8d, e and S8d, e). Occupied Ni 4p states were introduced at the top of the gap for the flat structure, with Ni 3d lying at the bottom of the gap. The wider gap of the more stable buckled monolayer again presented occupied Ni 4p states at the top of the gap, but exposed Ni 3d states lying in the parent material band gap at slightly destabilized energies. Introducing a Ni dopant to the bulk AB3c structure (Fig. 8f and S8f) opened the parent material band gap to almost 2 eV, with occupied Ni 3d states again appearing in the lower half of the parent gap. In this case, occupied Ni 4p states were stabalised to similar energies to the Ni 3d states, maintaining a nominal intrinsic band gap of around 0.7 eV. Fig. 9d–f indicates that the electron transfer from the Ni dopant was similar in the planar 2D and buckled bulk cases but reduced by more than 20% when the monolayer was allowed to buckle to a more stable configuration.
As a final independent piece of evidence that the layers of g-C3N4 are indeed buckled away from planarity, we present some experimental evidence. X-ray total scattering data for g-C3N4 was simulated via reverse Monte Carlo calculation with the RMCProfile code.38,39 During the RMC run, the atoms of g-C3N4 moved consistently away from planar structures in order to give a good fit to the X-ray scattering data, which could not be obtained from a structure comprised of flat planes of atoms. A side view of this real-space structure is shown in Fig. 10.
The out-of-plane displacements generated by the RMC simulation are similar in magnitude to those exhibited by our DFT structures. Note that the RMC structures maintained atomic positions consistent with the structure as a heptazine polymer throughout. Further details of these and related RMC simulations will be presented in a related paper.37
• The widely assumed planar (P
m2) model of g-C3N4 is neither energetically stable nor a reasonable approximation to the structure of ordered g-C3N4. Allowing out-of-plane atomic relaxation yields a lower-energy buckled structure that alleviates the in-plane N-lone-pair repulsion inherent to the planar model, whereas doping with heteroatoms is not required to induce buckling.
• In the layered heptazine-based g-C3N4 structure, the stacking patterns previously demonstrated to be the lowest in energy for flat layers are significantly higher in energy than other stacking patterns when the layers are buckled.
• The electronic structure of g-C3N4 is sensitive to both buckling and stacking registry. Although buckling generally widens the band gap relative to the planar monolayer, different corrugated stacking configurations yield distinct band gap values, which could potentially be an effective mechanism for tuning the electronic properties of bulk g-C3N4. For example, the corrugated stackings (P1 symmetry) uncovered in this study display varied electronic responses, with the band gaps of certain stacking configurations aligning closely with experimentally reported values. The most stable structure found in this work was the one labelled
while AB3c showed the best match to the experimental band gap (calculated at the HSE06 level).
• The calculated stability and electronic effect of representative metal and non-metal single atom dopants is strongly impacted by the treatment of both buckling and stacking.
We present a number of corrugation patterns that were calculated to be lower in energy than any of those previously reported. Key to these lower energy structures was the use of a 2 × 2 supercell within each plane, allowing adjacent heptazine units to buckle in opposite directions. The hexagonal structure of g-C3N4 suggests this alternation of structure may be frustrated in the third equivalent in-plane direction.
Within these corrugated structures, P and Ni dopants exhibit markedly different electronic responses compared with the flat model, demonstrating that dopant functionality depends primarily on the host structural motif. As such, reliable property prediction and rational design of both pristine and doped g-C3N4 require careful consideration of accurate structural models to enable the development of high-performance g-C3N4 photocatalysts. In particular, studying the effect of dopants by using DFT calculations based on either flat or buckled g-C3N4 monolayers is likely to be misleading if the target material is a synthesisable (i.e. multilayer or bulk) doped g-C3N4. Such calculations yield incorrect predictions of both the propensity of dopants to enter the g-C3N4 lattice and the effects of such dopants on the electronic (and hence photocatalytic) properties of the doped material.
| This journal is © The Royal Society of Chemistry 2026 |