Spanish authorities sent 16 water planes and helicopters to help fight five different forest fires Thursday as summer temperatures soared once again.

The Environment Ministry said it sent five planes to combat a blaze near the southern towns of Gualchos and Lujar. Some 500 people had been evacuated from the towns after the fire started Wednesday but authorities said Thursday it was safe enough for them to return home.

Planes and helicopters were also sent to help extinguish a fire that had destroyed 2,000 hectares (5,000 acres) of land around the south-central town of Quesada. Firefighters were also trying to put out fires that have razed 1,000 hectares in the provinces of southwestern Huelva, northern Huesca and eastern Castellon.

Spain has been hit by a heat wave for nearly two weeks, with temperatures reaching 40 C (104 F).