The worst power outage in 15 years struck most of Turkey on Tuesday, grounding flights and crippling rail networks. Localized blackouts continued as night fell.

Dogan News Agency reported that all provinces, apart from Van in the east, which receives energy from Iran were affected by the accident that took place at 10:36 a.m. local time. The energy ministry later said that the problem originated on the main Aegean lines, which distribute imported energy throughout the country.

Subway systems and traffic lights went down in several major urban centers, creating havoc on the streets, as an impromptu market opened on the streets for generator fuel. Thousands of people were also trapped for hours in elevators, and on funicular lines. Major industrial objects had to be shut down for the majority of the day.

By late afternoon, the energy ministry said that electricity had been restored to 90 percent of Istanbul, and would "shortly" be back in the remainder of the country.

Prime Minister Ahmet Davutoglu says all potential causes are still being investigated, “including the possibility of a terror attack,".

"Whether or not terrorism is a high possibility or a low one I can’t say at this stage. I can’t say either whether it is a cyber attack," energy minister Taner Yildiz told reports.

#hahaha#metroda#elektrik#kesildi#yürümeye#devam A video posted by Samet Kanberoğlu (@sametkanberogluu) on Mar 31, 2015 at 1:26am PDT





This is the first outage event of such magnitude in 15 years, according to the daily Hurriyet paper.

READ MORE: Major power outage throughout northern Holland (PHOTOS, VIDEO)

Electricity blackouts in at least 23 Turkish provinces including Ankara and Istanbul. Metro trains grind to a halt. — Isobel Finkel (@is_fink) March 31, 2015

Burası Taksim Metrosu elektrikler kesildi göç ediyoruz. pic.twitter.com/6WwFoDkRV2 — Tayfun Geçim (@tayfungecim) March 31, 2015