Hollow graphitic carbon nanofibers (HGCNFs) have great promise for many important applications, such as catalysis, sensors, energy conversion, gas storage, and electronic devices. Here, we report a catalytic etching-wettingdewetting mechanism in synthesizing HGCNFs with both hollow sphericallike and tunnel-like pores. With in situ transmission electron microscope imaging, we show that the spherical pores are formed by the evaporation of encapsulated Ni on the surface of amorphous carbon nanofiber and that hollow tunnels are developed through continuous etching of the amorphous carbon under catalysis of Ni nanoparticles. Theoretical calculations and simulations reveal that continuous tunnel etching is driven by the wetting-to-dewetting transition of the Ni-tunnel wall interaction during the catalytic graphitization of the amorphous carbon wall. In a typical application, we demonstrate that the synthesized HGCNFs, with a capacity about three times higher than that of their non-hollow counterparts, are excellent potential candidates for CO 2 capture.