To evaluate the impacts of nanopores of high‐rank coals on coalbed methane adsorption and storage, 12 anthracite and semianthracite coal samples from Yangquan and Shouyang blocks in the Qinshui Basin were investigated. Field emission scanning electron microscopy (FESEM) and CO2 adsorption combined with nuclear magnetic resonance cryoporometry (NMRC) experiments were used to evaluate the pore structure with diameters ranging from 0 to 500 nm and their impact on adsorption capacity based on qualitative and quantitative analysis. The results show that a coalification jump from semianthracite to anthracite occurred in the study area due to the magmatic intrusion. In the process, the volume of supermicropores and micropores largely increased while the volume of transition pores and mesopores decreased slightly. Additionally, vitrinite gets purified and enriched during the rapid maturation of coal reservoir, which is beneficial to the microporous structure development. The pore size distribution (PSD) of anthracite is mainly divided into two types, which are in serrated and decreasing forms, respectively. Higher vitrinite content can promote the formation of decreasing type (type II), which corresponds to a lower degree of complexity. The fractal dimensions indicate that the heterogeneity of coal samples is increasing with the decrease in pore size. Accordingly, the increase in pore heterogeneity corresponds to the lower adsorption capacity. The main pore sizes that contribute to CBM adsorption include two parts: 25‐30 nm and 50‐60 nm. For the supermicropores with large specific surface areas, the pore system detected by CO2 molecules is not conducive to CBM adsorption, while the increase in pore volume can improve the adsorption rate and capacity of CO2. These findings are vital for a precisely understanding of nanoscale pores as well as future CBM exploitation.