More than 1,000 firefighters battled a massive forest fire Monday in central Portugal that has killed at least 62 people, many of them burned to death in their cars.

The fire that erupted amid an intense heatwave and rainless thunderstorms has also injured at least 50 other people in the mountainous area of Pedrogao Grande, about 150 kilometers northeast of Lisbon.

Prime Minister Antonio Costa declared three days of national mourning, starting Sunday.

"Unfortunately, this seems to be the greatest tragedy we have seen in recent years in terms of forest fires," he said. "The priority now is to save those people who could still be in danger."

Police are searching charred areas of the forest and isolated homes for more bodies.

Spain and France are sending aircraft to assist in efforts to douse the flames, authorities say. The European Union also is mounting an emergency assistance campaign.

Portuguese National Republican Guard firefighters work to stop a forest fire from reaching the village of Avelar, central Portugal, June 18 2017.

United Nations Secretary-General Antonio Guterres, the former prime minister of Portugal, said he was "shocked and horrified" at the many lives claimed by the fires. The U.N. chief commended the government, firefighters, emergency responders and civil society organizations that are sparing no efforts to battle the wildfire and help people in need.

Jorge Gomes, secretary of state for the interior, said the flames moved "with great violence." He said it was "difficult" to determine whether the people who burned in their cars "were fleeing the flames or were taken by surprise."