N-doped carbon materials have garnered extensive development in electrochemical CO2 reduction due to their abundant sources, high structural plasticity, and excellent catalytic performance. However, the use of powder carbon materials for electrocatalytic reactions limits their current density and mechanical strength, which pose challenges for industrial applications. In this study, we synthesized a monolithic N-doped carbon electrode with high mechanical strength for efficient electrochemical reduction of CO2 to CO through a simple pyrolysis method, using phenolic resin as the precursor and ZIF-8 as the sacrificial template. At 900 °C, the decomposition of ZIF-8 and the volatilization of Zn atoms promote the formation of a hierarchical porous structure in the carbon matrix, characterized by macropores with extended mesoporous channels. Simultaneously, N active species derived from ZIF-8 are effectively generated around the pores and fully exposed. The efficient mass transfer facilitated by the hierarchical porous structure and high activity of exposed nitrogen species enables efficient conversion of CO2 to CO. When the ZIF-8 content is 30%, the catalyst achieves a Faradaic efficiency of 88.9% for CO at a low potential of -0.7 V (vs RHE), with a CO production rate of 244.05 μmol h-1 cm-2. After 50 h of potentiostatic electrolysis, the current density and FECO remain stable. This work not only provides a strategy for the synergistic effects of hierarchical porous structures and nitrogen doping but also offers an effective method to avoid using powder binders and prepare integrated, stable monolithic electrodes.