OAKLAND — PG&E will shift its headquarters to downtown Oakland starting in 2022 in an unexpected exit from San Francisco, the disgraced utility announced Monday, marking a major jobs coup for the East Bay’s largest city.

The revelation of PG&E’s shift to downtown Oakland — which would end more than a century of being headquartered in San Francisco — arrives during the final stages of the embattled utility’s bankruptcy, a court case spawned by PG&E’s financial woes in the wake of a string of lethal and disastrous wildfires in recent years.

“Our new Oakland headquarters will be significantly more cost-effective, is better suited to the needs of our business, and is a critical part of fulfilling our commitment to operate in a fiscally responsible way that will enable us to achieve our operational and safety goals,” said Bill Smith, the utility’s incoming interim chief executive officer.

Under normal circumstances, a relocation of the corporate offices of a storied company such as PG&E, which has maintained its headquarters in San Francisco for 115 years, would serve as an unqualified coup for Oakland and its downtown.

In this instance, however, the company involved is a member of a grim pantheon: America’s deadliest corporations. In March, PG&E agreed to plead guilty to 84 counts of involuntary manslaughter in the lethal Camp Fire that roared through Butte County in 2018.

PG&E intends to sell the San Francisco office complexes it now owns, at 77 Beale St. and 245 Market St. PG&E utility will seek approval from the state Public Utilities Commission to pass along to ratepayers the gains from the sale of the San Francisco properties.

The relocation will begin in 2022 and occur in phases over a period of a few years, PG&E said.

The utility also intends to consolidate two other East Bay locations, 3401 Crow Canyon Road in San Ramon and 1850 Gateway Blvd. in Concord, into the new downtown Oakland office.

TMG Partners, a principal owner of the 28-story office tower at 300 Lakeside, will renovate the downtown Oakland offices to PG&E’s specifications, marking an early example of how modern workspaces might be configured in an era of coronavirus-linked social distancing requirements.

PG&E intends to enter into a lease with an option to purchase the office tower. Those transactions must be approved by the U.S. Bankruptcy Court and the PUC.

The San Francisco properties could be choice morsels to tempt tech companies or other organizations that hunger for space in that city.

“We expect the sale of our San Francisco headquarters will unlock value in a notoriously tight real estate market,” said Andy Vesey, CEO of PG&E’s utility operations.

Due to a decade of disasters, PG&E has come under intense scrutiny.

In 2010, PG&E’s negligence, shoddy maintenance, and flawed recordkeeping caused a natural gas pipeline to rupture, unleashing a fireball that killed eight and destroyed a San Bruno neighborhood. A federal jury convicted PG&E in 2016 in a criminal trial for felonies the company committed before and after the San Bruno explosion.

In 2015, PG&E’s equipment started a fatal wildfire in Amador County and Calaveras County. In 2017, PG&E caused a series of lethal infernos in the North Bay Wine Country and other regions. In 2018, a PG&E equipment failure triggered a wildfire that roared through Butte County and destroyed the town of Paradise.

In May of this year, the PUC imposed a $1.97 billion penalty on PG&E for its role in the wildfires of recent years, a regulatory action that is believed to be the largest financial punishment ever imposed on an American utility.

The shift of the headquarters to downtown Oakland appears to represent more than a way to operate more efficiently. The relocation may also serve as a symbolic break for PG&E from the catastrophes it has caused over the deadly 10 years.

“Oakland is the perfect fit for us for a host of reasons,” PG&E’s Vesey said. “Oakland is a thriving hub of industry and innovation in our state, and we look forward to establishing our headquarters and contributing to life there.”