The invention discloses a novel contaminated site Hg in-situ detoxifying method based on biogas residues. The biogas residues, a carbon source and sulfate are prepared into an agent to be injected into Hg-containing soil in situ, then, a special construction and maintenance manner is adopted, fixed ecological fungicide gradually seeps into the ground, and the deep layer contaminated soil Hg is fixed. According to the method, the Hg-containing site with the high pollution depth can be repaired with the low cost and high efficiency, meanwhile, waste is treated through waste, and the biogas residues are treated.