Spring and fall are ideal times to visit nearly all of Spain, with the possible exception of the Atlantic coast, which experiences heavy rains in October and November. May and October are the best months, in terms of both weather and crowds.
In summer it's hot, hot, and hotter still, with the cities in Castile (Madrid) and Andalusia (Seville and Córdoba) heating up the most. Madrid has dry heat; the average temperature can hover around 84°F (29°C) in July and 75°F (24°C) in September. Seville has the dubious reputation of being about the hottest part of Spain in July and August, often baking under average temperatures of 93°F (34°C).
Barcelona, cooler in temperature, is often quite humid. Midsummer temperatures in Majorca often reach 91°F (33°C). The overcrowded Costa Brava has temperatures around 81°F (27°C) in July and August. The Costa del Sol has an average of 77°F (25°C) in summer. The coolest spot in Spain is the Atlantic coast from San Sebastián to A Coruña, with temperatures in the 70s (21°C-26°C) in July and August.
August remains the major vacation month in Europe. The traffic from France, the Netherlands, and Germany to Spain becomes a veritable migration, and low-cost hotels along the coastal areas are virtually impossible to find. To compound the problem, many restaurants and shops also decide it's time for a vacation, thereby limiting visitors' selections for both dining and shopping.
In winter, the coast from Algeciras to Málaga is the most popular, with temperatures reaching a warm 60°F to 63°F (16°-17°C). Madrid gets cold, as low as 34°F (1°C). Majorca is warmer, usually in the 50s (low teens Celsius), but it often dips into the 40s (single digits Celsius). Some mountain resorts can experience extreme cold.