Every so often, corporations confront questions of life or death. IBM did it in the 1990s when its hulking mainframe computers faced the challenge of next-generation PCs. A new chief executive successfully shifted IBM to services and software. Netflix did it — three times. It first played the role of disrupter, offering movie DVDs by mail and then mastering the business of online streaming. Then it changed again, generating its own content.

Now, BP, one of the world’s largest oil and gas companies, is aiming to ride the waves of disruption instead of being crushed under them. Led by a new chief executive, BP is trying to reinvent itself as an energy company in the age of climate change. The company is shrinking its oil and gas business, revving up offshore wind power, and developing solar and battery storage. It is even considering installing electric car charging kiosks at its gas stations, part of a drive to eliminate or offset its carbon emissions to a net-zero level by 2050.

“I can’t think of a company like that in the energy business,” Usher said.BP is giving it a try. On Thursday, the London-based oil giant said it would spend $1.1 billion for half ownership in Equinor’s wind projects off the shores of Massachusetts and New York, with the hope that the partnership will build more offshore wind projects in a global market expected to grow from 30 gigawatts now to more than 200 gigawatts by the end of the decade.

BP is adding this to a portfolio that includes a 50 percent ownership stake in European solar company Lightsource BP, which is developing projects.It’s just a start. The oil and gas company’s chief executive Bernard Looney, a drilling and production engineer, said on Aug. 4 that it aims to boost spending on low carbon projects from $500 million a year to $5 billion a year by the end of the decade. Even that larger figure, however, would be barely 40 percent of BP’s overall capital spending budget.

The company has also said it would consider installing electric vehicle recharging stations at many of the more than 7,000 retail gasoline stations in the United States. The company has already purchased Britain’s largest electric vehicle charging network and another network in China. And it plans to help cities and utilities buy packages of renewable energy and storage.

The need for a far-reaching corporate makeover as the planet warms is pressing, the company said. “There’s a fundamental belief about our business proposition: that the world actually demands more affordable clean energy,” said Dev Sanyal, chief executive of BP’s alternative energy business and a member of the company’s executive leadership team. “Providing the energy the world needs the way that it wants it — that is a shift in our strategy.”

After years of trying to impress investors by building bigger oil and gas reserves, BP earlier this year said it would stop looking for oil and gas in new areas and would slash oil and gas output by 40 percent. Last quarter it also sharply wrote down the value of its oil and gas reserves.