Calcium and magnesium ions in water create hardness in water. By removing these ions from the water, the water is softened.
The most preferred method to soften water is the use of strong acid-cation resin. One liter of resin generally removes 5000 oFr of hardness.
Hard water causes calcification in pipelines etc.