After a day or more without electricity, most North Bay residents were able to power up again Thursday morning.

The California utility PG&E restored power to about 150,000 customers by late Wednesday night, with thousands still left in the dark, including some in Napa County.

Facing severe fire conditions, the utility late Monday night cut power to its lines that serve about 172,000 customers in 22 Northern California counties. The “dry, hot weather with strong winds” posed a “significant fire risk,” the utility said Tuesday as the first shutdowns began.

By Wednesday night, power was fully restored in Alpine, Amador, Calaveras, El Dorado, Kern, Lake, Lassen, Mariposa, Nevada, Placer, Siskiyou, Sonoma, Tehama and Tuolumne counties. In Butte, Humboldt, Napa, Plumas, Sierra, Trinity and Yuba counties, there were about 5,000 customers who were still without electricity because PG&E had not yet been able to inspect the area, but the utility expects power in those counties to be fully restored by Thursday afternoon.

PG&E crews found 27 possible weather-related damages upon their initial inspection before restoring power. If PG&E had not cut the power, those could have ignited more wildfires, like the utility’s downed lines did in the deadly Camp Fire and others, the utility said.

Three of the four largest wildfires in California history have burned in the past month, but they were believed to be ignited by a siege of lightning strikes, not downed power lines.