A magnetic hydrothermal carbon material(MHC) coated with Fe3O4 nanopaticles was firstly prepared by solvothermal method,using renewable agricultural waste corn silk as the carbon precursor,ferric chloride(FeCl3·6H2O) as the source of iron.Then,a biomass derived activated magnetic porous carbon(AMC) was successfully fabricated via pyrolysis treatment of MHC using KOH as activating reagent.This magnetic nanocomposite,with a well developed porous structure,provided a large number of activated sites for the target absorption.Besides,the iron oxide(Fe3O4 and Fe2O3) homogeneously distributed on the surface of the carbon matrix.AMC exhibited a remarkable adsorption performance toward malachite green(MG),and the maximum adsorption capacity reached up to 312.5 mg/g obtained from the Langmuir isotherm.Combined with ultra high performance liquid chromatography(UPLC),AMC was served as a magnetic solid phase extraction(MSPE) adsorbent to detect MG in water.The important parameters influencing the extraction performance of the adsorbent were investigated and optimized.The best extraction results were obtained when 6 mg AMC was applied to extract MG in 100 mL sample solution(pH 7.0) for 20 min,using a mixture of methanol-acetic acid(9∶1,by volume) as eluent.Results showed that there was a good linear relationship for MG in the concentration range of 0.05-5 μg/L,with correlation coefficient(r) of 0.999 6.The limit of detection(LOD) was 0.01 μg/L,and the limit of quantitation(LOQ) was 0.03 μg/L.The spiked recoveries for MG in the seawater samples ranged from 104% to 106%,with RSDs of 1.7%-3.4%.The developed method was suitable for the detection of MG in aquacultural seawater.