A novel magnetic sulfur-doped porous carbon (MSPC) was fabricated via a simple one-step carbonization of a mixture of sucrose, basic magnesium sulfate whiskers and [email protected] nanoparticles. Due to the high S content, the prepared MSPC possessed high adsorption capacity for Hg2+ (343 mg g-1) with good selectivity. Based on this, a method coupling magnetic solid phase extraction (MSPE) with inductively coupled plasma mass spectrometry (ICP-MS) was developed for the determination of trace Hg2+ in environmental water samples. Various parameters such as pH, desorption solvent and its concentration, desorption volume and time, sample volume, and adsorption time that affect the determination have been optimized. Under the optimal conditions, a high enrichment factor of 100-fold was obtained, the limit of detection (LOD) was found to be 0.52 pg mL-1 with a relative standard deviation (c = 10 pg mL-1, n = 7) of 7.1%, and a good linearity was obtained within the concentration range of 2-5000 pg mL-1 for Hg2+. Besides, the proposed method has very fast adsorption/desorption kinetics, target Hg2+ could be rapidly adsorbed on the prepared MSPC in 2 min and desorbed from the MSPC in 2 min with the assistance of a permanent magnet. Therefore, the proposed method of MSPE-ICP-MS exhibits good application potential in the determination of trace Hg2+ in environmental water samples.