Firefighters in Portugal and Spain are battling scores of wildfires after a week of the worst fire destruction in years on the mountainous Iberian Peninsula.

Stoked by winds and high temperatures, the wildfires have killed at least four people in Portugal and one in Spain over the last week and forced hundreds to flee their homes.

On Monday, authorities in Portugal said almost 2,000 firefighters supported by 10 water-dumping aircraft were tackling more than 40 different fires throughout the country. One of the most stubborn blazes, however, has been brought under control near the central town of Sao Pedro do Sol.

In Spain, 10 water-dumping planes and helicopters helped ground crews attack flames in the north-western province of Galicia, which has lost around 7,000 hectares (17,300 acres) to fire.

Five firefighters were taken to hospital, four due to smoke inhalation and one from injuries received in a road accident, Galicia's government said.

Televised images from both countries showed residents dousing homes and nearby woods to try to stave off the flames throughout Sunday night and into Monday morning.

Last week more than a dozen major wildfires forced the deployment of almost 4,500 firefighters throughout Portugal.

The worst fire reached the capital of the Atlantic Ocean island of Madeira, where it killed three elderly people, injured more than 300 and razed homes and a hotel.

Spanish police have made several arrests of alleged arsonists suspected of setting some of the fires.

One particularly devastating fire on the Canary Islands was started unintentionally when a German man tried to burn his soiled toilet paper, sparking a conflagration that destroyed 4,000 hectares (9,900 acres) of forest on La Palma.