MADRID — Power was almost entirely restored in Spain and Portugal early Tuesday, after a massive outage hit tens of millions of people across the countries and parts of France, grounding aircraft, disrupting traffic and bringing daily life to a grinding halt.
All 6.4 million electricity consumers in Portugal were once again receiving power, the country's government said Tuesday, adding that while trains and airports had resumed operations, there was still “some recovery to be done” at Lisbon’s main airport.
In Spain, the other country on the Iberian Peninsula, grid operator Red Electrica said in a post on X that more than 99% of the peninsula’s demand was being served and that all of its substations were operational again.
Power failures of this scale are rare in Europe, and when the outage hit around noon Monday (6 a.m. ET), airports were disabled and shops and offices were plunged into darkness.
It took the better part of a day to restore full power to at least two major European economies — the tiny principality of Andorra in the Pyrenees Mountains was also hit.
Spanish hospitals suspended routine medical work and several oil refineries were shut down. In Madrid, the Mutua Madrid Open tennis tournament was canceled, with players forced to leave the court midmatch when scoreboards and cameras went dark.
Despite the recovery, both Spain and Portugal remained in a state of emergency for a second day Tuesday.

Portuguese Prime Minister Luis Montenegro said Monday he did not know what caused the blackout but said “everything indicates” that it originated in neighboring Spain. His Spanish counterpart, Prime Minister Pedro Sanchez, said Monday he was also not sure what caused the problem.
“It is better not to speculate,” Sanchez said Monday.
Videos on social media and verified by NBC News showed residents of both countries cheering as power was slowly restored late Monday. People could be heard cheering and clapping in celebration in both Madrid and Barcelona as streets suddenly lit up.
Some might have preferred the blackout to go on for just a little longer.
Residents in Barcelona and Madrid poured into the streets amid the mayhem, taking the opportunity to disconnect, dance and enjoy picnics in the cities’ sun-drenched parks. Videos posted on TikTok documenting the relaxed atmosphere were given titles such as “digital detox” and “a good excuse to party.”
Even if they had tried, they may not have been able to get anywhere quickly.
Hundreds were stranded in elevators, with Madrid’s emergency management office saying Monday that it had conducted almost 200 elevator rescues. Videos from the Spanish capital showed passengers walking to safety through darkened subway tunnels illuminated by emergency lights.
Traffic signals were rendered out of order, forcing the Spanish Civil Guard police force to help coordinate traffic, which quickly clogged the city's streets, and to help evacuate passengers from stalled trains.
Rail outages and disruptions to phone service stranded American tourists Drew Terrono, 70, and Shelley Charnoff, 68, when they tried to get back to Madrid following a tour of a cathedral in the nearby city of Toledo.
“No connection with anybody, and no access to any information in English about what was going on at the time,” Charnoff, told NBC News. The two eventually found a taxi to take them back to the city, he added.

Videos posted on Instagram showed some travelers, despite warnings from airports and authorities not to do so, dragging their luggage to Madrid’s airport after failing to find transportation.
“We didn’t know the way to airport. And taxis didn’t want to drive us,” Kate Voloshchuk, a Ukrainian tourist on a three-day trip to Madrid, told NBC News.
“We have blackouts very often, so every place is ready for such situation,” she said. “But for Madrid, it is real apocalypse.”
Ukraine, which has faced Russian airstrikes on its energy infrastructure for the past three years, extended a helping hand, with President Volodymyr Zelenskyy saying he instructed the country's energy minister to provide support. "Our technical experts are ready to help," he said in a post on X on Monday.
In the event, Ukrainian help may not have been necessary. Spain, according to Portuguese electric company Rede Elétrica Nacional, got back online by making some of its own power and receiving some from France and Morocco, while Portugal made its own.
Raf Sanchez reported from Madrid and Mithil Aggarwal from Hong Kong.