The urban environment is a complex ecosystem influenced by strong human disturbances in multi-environmental media, so it is necessary to analyze urban environmental pollutants through the comprehensive analysis of different media. Soil, road dust, foliar dust, and camphor leaves from 32 sample sites in Shanghai were collected for the analysis of mercury contamination in soil–road dust–leaves–foliar dust systems. Mercury concentrations in surface soils in Shanghai were the highest, followed by road dust, foliar dust, and leaves, successively. The spatial distribution of mercury in the four environmental media presented different distribution patterns. Except for the significant correlation between mercury concentrations in road dust and mercury concentrations in leaves (r = 0.56, p < 0.001), there was no significant correlation between the other groups in the four media. Besides this, there was no significant correlation between mercury concentrations and land types. The LUR (Land use regression) model was used to assess the impact of urbanization factors on mercury distribution in the environment. The results showed that soil mercury was affected by factories and residential areas. Foliar dust mercury was affected by road density and power plants. Leaf mercury was affected by power plants and road dust mercury was affected by public service areas. The highest average HI (Hazard index) value of mercury in Shanghai was found in road dust, followed by surface soil and foliar dust. The HI values for children were much higher than those for adults. However, the HI values of mercury exposure in all sampling sites were less than one, suggesting a lower health risk level. The microscopic mechanism of mercury in different environmental media was suggested to be studied further in order to learn the quantitative effects of urbanization factors on mercury concentrations.