Firefighters in Spain's Catalonia province said they were aided by six water-dropping planes and helicopters.
"We're working together with French firefighters on a fire at la Jonquera," they tweeted.
Catalan fire brigade tweets aerial view of fire
Imatge de l'incendi a la Jonquera, afecta vegetació situada entre AP-7 (tallada ara en ambdós sentits de la marxa) i N-II (tallada pk 776 sentit nord), segons confirma @mossos. Hi treballen 6 #maer i 10 vehicles #bomberscat pic.twitter.com/SgJhe9eOgFBombers (@bomberscat) 4 août 2018
The fire started at about 5.30pm, according to French officials, and was brought under control later in the evening.
But traffic was stopped on the road as it raged, leading some motorists to complain that their tolls soared through no fault of their own.
Motorist complains of closed tollgates
@A9Trafic Merci beaucoup de ne pas avoir levé les barrières. Plus de deux heures arrêtées et 30€ (traductor)Fran Vico (@Mothhor) 4 août 2018
Y gracias @transitap7 por no levantar barreras en Junquera después de más de 2 horas parados!
This weekend sees the heaviest traffic of the year in France, with conditions made even more difficult by the heatwave that has hit much of Europe.
The authorities have advised drivers to avoid peak hours and take measures such as drinking water to protect their health and that of their passengers, especially children and the elderly.