Cadmium ( Cd) and lead (Pb) in water and soil could be adsorbed by biochar produced from corn straw. Biochar pyrolyzed under 400 degrees C for 2 h could reach the ideal removal efficiencies (99.24% and 98.62% for Cd and Pb, respectively) from water with the biochar dosage of 20 g.L-1 and initial concentration of 20 mg.L-1. The pH value of 4-7 was the optimal range for adsorption reaction. The adsorption mechanism was discussed on the basis of a range of characterizations, including X-ray diffraction (XRD), X-ray photoelectron spectroscopy (XPS), Fourier transform infrared spectroscopy (FTIR) and Raman analysis; it was concluded as surface complexation with active sorption sites (-OH, -COO-), coordination with pi electrons (C = C, C = O) and precipitation with inorganic anions (OH-, CO32-, SO42-) for both Cd and Pb. The sorption isotherms fit Langmuir model better than Freundlich model, and the saturated sorption capacities for Cd and Pb were 38.91 mg.g(-1) and 28.99 mg.g(-1), respectively. When mixed with soil, biochar could effectively increase alkalinity and reduce bioavailability of heavy metals. Thus, biochar derived from corn straw would be a green material for both removal of heavy metals and amelioration of soil. (C) Higher Education Press and Springer-Verlag Berlin Heidelberg 2017