Herein we report a general dual-templating approach to prepare hierarchically macro-/meso-/microporous heteroatom-doped carbon materials using diverse low-cost biomass precursors. Nitrogen/oxygen-doped carbon materials with hierarchical porosity are first synthesized as an example using Mg5(OH)2(CO3)4/ZnCl2 as hard templates and glucose/urea as carbon and heteroatom sources through a high-temperature thermal reaction and subsequent etching treatment. This approach is very versatile and can be applied to produce many hierarchically structured heteroatom-doped carbon materials via pyrolysis of other biomass precursors, including roots, stems, leaves, flowers and fruits of various plants. Lastly, we demonstrate that the as-prepared hierarchically porous nitrogen/oxygen-doped carbon materials manifest enhanced electrocatalytic performance for oxygen reduction reaction in alkaline electrolyte.
