Soybean straw (SS)-based activated carbon was employed as a precursor to prepare carbon molecular sieves (CMSs) via chemical vapor deposition (CVD) technique using methane as carbon source. Prior to the CVD process, SS was activated by 0.5 wt% ZnCl2, followed by a carbonization at 500°C for 1 h in N2 atmosphere. N2 (77 K) adsorption-desorption and CO2 (273 K) adsorption tests were carried out to analyze the pore structure of the prepared CMSs. The results show that increasing the deposition temperature, time or methane flow rate leads the decrease in N2 adsorption capacity, micropore volume and average pore diameter of CMSs. The adsorption selectivity coefficient of CO2/CH4 achieves as high as 20.8 over CMSs obtained under the methane flow rate of 30 mL min–1 at 800°C for 70 min. The study demonstrates the prepared CMSs are a candidate adsorbent for CO2/CH4 separation.