The separation of metal ions with different valences is an intractable challenge in the treatment of rare earth (RE) ore leaching solutions, and nanofiltration (NF) is one of the most promising approaches to separate ions with different valences. Therefore, the separation behaviors of three commercial NF membranes (NF5, NF270 and NF90) were investigated in this study. The results showed that NF technology could be used for the separation of cations with different valences from nitrate and chloride; the NF270 membrane could be used for the separation of Na+/Ca2+ due to its appropriate pore size and negative charge. The NF5 membrane could be used for Ca2+/Nd3+ separation due to its large pore size and suitable zeta potential. Increasing the operating pressure and cross-flow velocity was beneficial to increase the separation factor of Ca2+/Nd3+. Increasing the solution pH and salt concentration facilitated the adsorption of metal cations on the membrane surface, resulting in the separation factor of Ca2+/Nd3+ increasing first and then decreasing. This work may provide new strategies to recycle valuable metals from RE wastewater or other complex mediums.