To understand the interaction mechanism between adsorbent and adsorbate, activated biochar, prepared from pine sawdust using CO2 and H2O as activator, was employed to adsorb methylene blue in printing and dyeing pollutants. The pore structure, carbon structure of the aromatic ring system, and functional groups were investigated though SEM, nitrogen adsorption/desorption device (BET), Raman, and XPS characterization, and the adsorption kinetics and possible adsorption mechanism were also studied. The results showed that the activated biochar prepared by CO2 activation had more specific surface area, pore structure, and surface oxygen-containing functional groups than that prepared by H2O, which was more conductive to improving its adsorption capacity. The electrostatic interaction between the surface oxygen-containing functional groups in the adsorbents and the π-π interaction formed in the aromatic rings enhanced the adsorption capacity of activated biochar to methylene blue. The adsorption process of methylene blue by activated biochar was spontaneous, and it conformed to the pseudo-second-order kinetic characteristics and Langmuir adsorption isotherm equation. It was a monolayer adsorption and the maximum adsorption capacity was about 160 mg/g. Activated biochar as an adsorbent for wastewater treatment has promising application and development prospects.