Most of the water softeners use the ion exchange process to remove minerals that cause your water to be hard. Water softeners exchange calcium and magnesium ions with sodium or potassium (if potassium chloride salt use) ions and make your water soft.
On the other hand, reverse osmosis systems use a semi-permeable membrane to filter impurities from water. Reverse osmosis can improve the quality of your water. But when you need to remove water hardness, an RO system is less effective than a water softener system.