Na+/Ca2+ exchangers use the Na+ electrochemical gradient across the plasma membrane to extrude intracellular Ca2+ and play a central role in Ca2+ homeostasis. Here, we elucidate their mechanisms of extracellular ion recognition and exchange through a structural analysis of the exchanger from Methanococcus jannaschii (NCX_Mj) bound to Na+, Ca2+ or Sr2+ in various occupancies and in an apo state. This analysis defines the binding mode and relative affinity of these ions, establishes the structural basis for the anticipated 3:1 Na+/Ca2+-exchange stoichiometry and reveals the conformational changes at the onset of the alternating-access transport mechanism. An independent analysis of the dynamics and conformational free-energy landscape of NCX_Mj in different ion-occupancy states, based on enhanced-sampling molecular dynamics simulations, demonstrates that the crystal structures reflect mechanistically relevant, interconverting conformations. These calculations also reveal the mechanism by which the outward-to-inward transition is controlled by the ion occupancy, thereby explaining the emergence of strictly coupled Na+/Ca2+ antiport.