Temperatures passed 40 degrees Celsius (104 Fahrenheit) in large parts of Spain, significantly higher than normal for this time of year.
Fifteen out of Spain’s 17 regions were on alert for very high temperatures, with only the Canary Islands and Asturias being spared.
Officials advised people to drink plenty of fluids and stay indoors or in the shade as much as possible.
“This early, record-breaking heatwave, coming on top of another heatwave less than a month ago… is extraordinarily worrying,” said Spain’s minister for ecological transition, Teresa Ribera.
Temperatures were expected to hit 43C in Córdoba in the south, 41C in Badajoz in the west and 40C in Toledo in the centre, according to meteorological agency AEMET.
On Monday the highest temperature recorded was 42.9C in the southern town of Montoro, near Córdoba.
AEMET described the risk of wildfires as “extreme” across Spain except for the northern region of Asturias and the Canary Islands in the Atlantic.
The heatwave began at the weekend and is expected to persist until at least Saturday, with temperatures between 7C and 12C higher than the average for this time of the year, said AEMET.
“It is not normal to have such an extreme heatwave at this time of the year,” AEMET spokesman Ruben del Campo said.
It’s the earliest heatwave since there are records – together with another one in 1981 – and “it’s the most intense heatwave in mid-June in the last 20 years”, del Campo added.
The extreme weather, which arrived on a wave of hot air from north Africa, is headed for southwest France.
National forecaster Meteo France has warned of peak temperatures of more than 40C in the south-west between Thursday and Saturday, with the whole country set to experience a hotter-than-usual spell.
French government spokesperson Olivia Gregoire called for vigilance, warning that the elderly, people living alone and the homeless were particularly at risk.
Spain grappled with a heatwave at the end of May, with temperatures up to 15C above the seasonal average.
Last month was Spain’s hottest May since the beginning of the century.
Heatwaves have become more likely due to climate change, scientists say, and are predicted to become more intense and widespread as global temperatures rise.