Quality of water in Spain
Generally water in urban areas of Spain is described as perfectly ok to drink. However, the quality can vary from perfect to brown and having a nasty taste. Most people in Spain prefer to drink bottled water, regardless of the quality of the mains water supply.
In rural areas some water supplies can be tainted by chemicals and fertilsers used on the land. Whilst boling water will kill bacteria, it will not remove chemical impurities. You should consider installing a water filter.
Many areas have hard water containing high concentrations of calcium and magnesium. Water is very hard (muy dura) in the east, hard (dura) in the north and most of the south, and soft in the north-west (e.g. Galicia), and central and western regions.
You can install a water softener that prevents the build-up of scale in water heaters and water pipes which increases heating costs and damages electric heaters and other appliances. Costs vary considerably and can be hundreds of euros for a sophisticated system, which also consumes large quantities of water for regeneration.