The quality of Spanish healthcare and facilities available to patients probably equals anywhere in Europe and betters most. The Spanish are among the world's healthiest people and have the highest life expectancy in the EU. The incidence of heart disease in Spain is among the lowest in the world, a fact attributed to the Spanish diet, which includes considerable quantities of garlic, olive oil and red wine.
As with the UK, Spain has a public health system that provides free or low cost health care for those contributing to the Spanish social security system and their families. The system also caters for retirees and includes those from other EU countries. Spain has an excellent system of private medicine that exists alongside the state system with both operated, so as to compliment each other.
If you are an EU national, retired and in receipt of a state pension you are fully covered for all aspects of health care in Spain including totally free drugs and medications. If you are not entitled to benefits from the Spanish social security system then you must have private insurance.