France is preparing to use a massive specially adapted cargo aircraft to dump flame retardants on a wildfire that has forced the evacuation of tens of thousands of people.

Including 70,000 people evacuated in central Spain, wildfires in southern Europe this week have displaced more than a quarter of a million people.

French interior minister Laurent Nunez said the A400M aircraft will join what is expected to be a “long and very difficult” battle against the blaze raging in the Gironde region of south-western France.

With winds expected to shift in a west-to-east direction on Saturday afternoon, potentially driving the fire closer to Bordeaux, fire crews and authorities were digging trenches, using retardants and taking other steps to block it, Mr Nunez said. He said the fire was about 20 miles west of the city.

The government mobilised soldiers to join the battle and was rushing in 1.5 million face masks to protect against choking smoke.

Authorities ordered people between the fire and Bordeaux to evacuate, including from parts of the city’s western suburbs and other towns and villages.

Prime Minister Sébastien Lecornu described the fires as unprecedented and said the Gironde blaze had become so strong it was generating its own winds.

“Our priority is clear: protecting human lives,” he posted on X, adding that evacuation orders “must be respected without delay”.

He said firefighting teams were being reinforced with the addition of hundreds of soldiers and that breathing masks to filter out smoke particles were being rushed to the Gironde region for those exposed to the clouds of potentially noxious fumes.

The virulence of the wildfires, fuelled by high temperatures and the long-term effects of climate change, caught fire crews and authorities off guard in both countries.

Firefighters in Spain said the blazes spread so fast and violently that they could not be tackled head on. In France, some people even fled by boat when flames swept through tourist towns on the Atlantic coast.

Dozens of French firefighters have been injured, authorities said, but no deaths were reported in either country despite scenes of panic as residents fled by car and police went door to door to tell people to leave as large plumes of smoke darkened the skies.

Successive heatwaves that hit unusually early and hard this year, baking Europe with record-shattering high temperatures, have turned forests and scrublands into tinderboxes.

Fires have burned 130,000 hectares of forest already this year in Spain, up from an annual average of 100,000 hectares over the past decade, Prime Minister Pedro Sánchez said on Saturday as he visited a command post west of Madrid.

He said more favourable weather on Saturday offered “a window of opportunity” for fire crews to bring the blazes under control. Madrid’s regional government said the fires decreased in intensity as winds and temperatures dropped.

Other European nations were helping. Italy said two of its Canadair water-dumping firefighting planes had been deployed to Spain. Spain’s Civil Protection Service said it was expecting the arrival of two others from Greece, to join aircraft from the Netherlands and Portugal already deployed in Spain.

France is expecting two water-bombers from Croatia as well as two other planes from Portugal and two heavy-lift Black Hawk helicopters from the Czech Republic and Slovakia.

Gironde region prefect Sophie Brocas said on Friday night that strong winds from the west were pushing the fire closer to the Bordeaux metropolitan area and that it had grown to “an unprecedented magnitude”.

Western suburbs covered by evacuation orders included Le Haillan and parts of Eysines and Mérignac, where the city’s airport is located. The airport said it remained open but that bus and tram services were suspended.

Evacuation orders were sent with special alerts to mobile phones, instructing people to leave, Ms Brocas said.

“We want everyone to be quickly brought to safety. We must act quickly together,” she said.

The Gironde blaze broke out on Wednesday near the Cap Ferret peninsula on France’s Atlantic coast, 37 miles from Bordeaux.