Background: Gene duplication events have been proposed to be involved in the adaptation of plants to stress conditions; precisely how is unclear. To address this question, we studied the evolution of two families of antiporters. Cation/proton exchangers are important for normal cell function and in plants, Na+, K+/H+ antiporters have also been implicated in salt tolerance. Two well-known plant cation/proton antiporters are NHX1 and SOS1, which perform Na+ and K+ compartmentalization into the vacuole and Na+ efflux from the cell, respectively. However, our knowledge about the evolution of NHX and SOS1 stress responsive gene families is still limited. Results: In this study we performed a comprehensive molecular evolutionary analysis of the NHX and SOS1 families. Using available sequences from a total of 33 plant species, we estimated gene family phylogenies and gene duplication histories, as well as examined heterogeneous selection pressure on amino acid sites. Our results show that, while the NHX family expanded and specialized, the SOS1 family remained a low copy gene family that appears to have undergone neofunctionalization during its evolutionary history. Additionally, we found that both families are under purifying selection although SOS1 is less constrained. Conclusions: We propose that the different evolution histories are related with the proteins' function and localization, and that the NHX and SOS1 families are examples of two different evolutionary paths through which duplication events may result in adaptive evolution of stress tolerance.