In this paper, an experimental system for the migration of underground contaminants outside borehole heat exchanges (BHEs) at laboratory scale is established, and the migration laws of contaminants under different temperature conditions are studied. The results show that: Compared with room temperature conditions, the diffusion rate of underground contaminants in both horizontal and vertical directions increases under heat injection conditions of BHEs; while under heat extraction conditions, the diffusion rates of contaminants decreases in the vertical direction and increases in radial direction. This is due to the temperature difference between the soil near the borehole wall and the distant soil under the two conditions, which changes the viscosity of contaminant and finally affects its diffusion. In addition, contaminants were detected above the leak point under heat injection conditions. This is because there is a temperature difference between the borehole wall and the formation, which caused upward natural convection, driving the contaminants move to the upward direction. The concentration of contaminants at the radial distance of 2 cm and 5 cm from the leakage point was measured, indicating that the closer to the leakage point, the greater the concentration of contaminants.