Biochar has been widely recognized as a promising solid CO
2 adsorbent with economic and ecological benefits. Industrial CO
2 emissions originate from diverse sources, while the pore structure and chemical functional groups of biochar exhibit varying degrees of influence on CO
2 adsorption and separation performance under different adsorption conditions. Therefore, exploring the matching relationship between the physicochemical properties of biochar and its adsorption and separation performance at different adsorption conditions is essential for the development and optimization of carbon-based adsorbents. This study selected the high-performance extreme gradient boosting (XGB) algorithm from various algorithms and utilized it to develop CO
2, N
2, CH
4 adsorption prediction models. Based on this, coupled prediction models were developed for CO
2/N
2 and CO
2/CH
4 adsorption selectivity. Furthermore, feature importance and partial dependence analysis were performed using SHAP values. The results indicate that during CO
2 adsorption, the influence of the pore structure of biochar outweighs that of its chemical composition. Specifically, the pore structure of 0.4-0.6 nm is the most important property influencing CO
2 adsorption at low and medium pressure (0-0.6 bar), and the pore structure of 0.6-0.8 nm, as well as the specific surface area contribute the most at high pressure (0.6-1 bar). During CO
2 selective separation, the CO
2/N
2 mixture is primarily separated through the selective adsorption of CO
2 by nitrogen functional groups. In contrast, for CO
2/CH
4 mixtures, pore structure <1 nm plays a more critical role in determining adsorption selectivity. In addition, molecular simulation studies further revealed the adsorption filling mechanisms of CO
2 molecules within different pore sizes and functional groups. Finally, nitrogen-doped biochar was synthesized using de-alkalize lignin as the precursor, KOH as the activating agent, and urea as the nitrogen dopant. CO
2, N
2, and CH
4 isothermal adsorption experiments were conducted, and the experimental results confirmed that the developed prediction models exhibit high accuracy (
R2>0.9).