Marco della Cava

USA TODAY

SAN FRANCISCO — Residents of this bayside city are no longer powerless, as workers finally restored electricity late Friday to all 90,000 people who spent the day in the figurative dark.

Pacific Gas & Electric "reports all power has been restored. Thank you to everyone that kept our City safe," San Francisco mayor Ed Lee tweeted late Friday.

The outage left roughly 1 in 10 residents without electricity. The cause was a fire at a power substation.

“We had equipment failure, the catastrophic failure of a circuit breaker,” Pacific Gas & Electric spokesperson Barry Anderson told KCBS. “When it failed, it created a fire in the insulation surrounding the breaker … Something went wrong with the breaker to cause it to explode.”

The blackout affected businesses and schools, kicking off an unexpected three-day weekend around 9 a.m. when power first went out.

Large office buildings in the city's Financial District, not far from the fabled Ferry Building, began emptying out not long after the outage hit around 9 a.m. Schools around the city dismissed students, while cable cars stopped shuttling visitors up and down the city's steep streets.

A major commuter station in the city's Bay Area Rapid Transit network, the Montgomery Street BART hub, went dark as travelers sought alternative means of transportation ranging from ride hailing cars to shuttles organized by the city.

City officials began tackling the problem almost immediately, with power gradually coming back to residents in waves throughout the day.

Also Friday, an outage also hit New York, where subway riders found their commutes temporarily halted due to an electrical line failure, a Con Edison spokesperson told CBS2.

Contributing: Jessica Guynn

Follow USA TODAY tech reporter Marco della Cava on Twitter.