Herein, a novel functionalized magnetic metal-organic framework (MOF) was synthesized and utilized for the extraction and determination of Hg(II) ions in food samples. This is the first report on the modification of magnetite@Co-MOF-71 with 1,3,4-Thiadiazole-2,5-dithiol chelator and its application for the separation/enrichment of Hg(II) ions in food samples. The synthesis of new material was confirmed by performing SEM, TEM, VSM, and FT-IR tests. An experimental design approach was employed to optimize the extraction conditions. In this way, the following condition provided the highest uptake percentage: pH of the sample, 5.0; uptake time, 9.0 min; adsorbent dosage, 18 mg. For the elution step, the best condition was obtained by utilizing 0.7 mol L-1 HCl solution (0.8 mL) as an eluent for 11 min. Determination of mercury was performed on a cold vapor atomic absorption spectrometer. The LOD, LOQ, and linear dynamic range for the proposed extraction method were 0.004 mu g L-1, 0.01 mu g L-1, and 0.01-40 mu g L-1, respectively. The repeatability of the new method at three concentration of 0.01, 2.0, 40 mu g L-1 (n = 3) was 13.0%, 10.5%, and 7.3%, respectively. In the end, the new method was employed for the determination of ultra-trace amounts of Hg(II) ions in food samples, and satisfactory results were achieved (Recovery, 85-110%; RSD%, 4.7-11.8%).