As a crucial sink of metal-containing nanoparticles (MNPs), road dust can record their spatiotemporal variations in urban environments. In this study, taking Shanghai as a representative megacity in China, a total of 272 dust samples were collected in the winter and summer of 2013 and 2021/2022 to understand the spatiotemporal variations and driving factors of MNPs. The number concentrations of Fe-, Ti-, and Zn-containing NPs were 3.8 × 106 − 8.4 × 108, 2.3 × 106–1.4 × 108, and 6.0 × 105–2.3 × 108 particles/mg, respectively, according to single particle (sp)ICP-MS analysis. These MNPs showed significantly higher number concentrations in summer than in winter. Hotspots of Fe-containing NPs were more concentrated in industrial and traffic areas, Zn-containing NPs were mainly distributed in the central urban areas, while Ti-containing NPs were abundant in areas receiving high rainfall. The structural equation model results indicates that substantial rainfall in summer can help remove MNPs from atmospheric PM2.5 into dust, while in winter industrial and traffic activities were the primary contributors for MNPs. Moreover, the contribution of traffic emissions to MNPs has surpassed industrial one over the last decade, highlighting the urgency to control traffic-sourced MNPs, especially those from non-exhaust emissions by electric vehicles.