Zinc and cadmium are similar metal ions, but though Zn(2+) is an essential nutrient, Cd(2+) is a toxic and common pollutant linked to multiple disorders. Faster body turnover and ubiquitous distribution of Zn(2+) vs. Cd(2+) suggest that a mammalian metal transporter distinguishes between these metal ions. We show that the mammalian metal transporters, ZnTs, mediate cytosolic and vesicular Zn(2+) transport, but reject Cd(2+), thus constituting the first mammalian metal transporter with a refined selectivity against Cd(2+). Remarkably, the bacterial ZnT ortholog, YiiP, does not discriminate between Zn(2+) and Cd(2+). A phylogenetic comparison between the tetrahedral metal transport motif of YiiP and ZnTs identifies a histidine at the mammalian site that is critical for metal selectivity. Residue swapping at this position abolished metal selectivity of ZnTs, and fully reconstituted selective Zn(2+) transport of YiiP. Finally, we show that metal selectivity evolves through a reduction in binding but not the translocation of Cd(2+) by the transporter. Thus, our results identify a unique class of mammalian transporters and the structural motif required to discriminate between Zn(2+) and Cd(2+), and show that metal selectivity is tuned by a coordination-based mechanism that raises the thermodynamic barrier to Cd(2+) binding.