Local residents, including 30 people from a retirement home, had to be evacuated to safety as the fire approached.
Hundreds of firefighters in Portugal are battling a huge forest fire that broke out 30 kilometres north of the capital Lisbon.
High temperatures and strong winds made work difficult for more than 400 firefighters trying to tackle the blaze which started on Sunday, with five water tankers also deployed to the area.
A huge cloud of black smoke billowed over the town of Venda do Pinheiro, in Mafra, with the fire forcing authorities to block several roads and evacuate a care home. Many locals left their homes out of fear, although some tried to beat the flames by using hoses to water their gardens and property.
Smoke rising from the fire could even be seen from Lisbon's city centre.
Like other European nations, Portugal experienced a scorching heatwave in recent weeks, with temperatures exceeding +40°C in various parts of the country. Although the heat had eased, temperatures are climbing again.
Portugal's weather agency IPMA says that three districts in the north of the country are on "red alert" for extreme heat on Monday, and more than a thousand firefighters are mobilised across the country to tackle other wildfires.
In Ourem in central Portugal, a river beach was evacuated as a precautionary measure, according to a rescue official quoted by the Lusa agency.
Interior Minister José Luis Carneiro said on Sunday evening that plans were in place to activate another red alert on Tuesday in the districts of Vila Real, Bragança, Guarda and Viseu because of extreme fire risk.
Portugal, still traumatised by the 2017 fires that killed more than 100 people, was already hit in early July by a series of fires fanned by scorching temperatures.
Since the beginning of the year, more than 58,000 hectares have gone up in smoke according to data from the Institute for Nature and Forest Conservation (ICNF).