General Motors is promising to go green by making all of its global operations and vehicles carbon neutral by 2040, including selling only zero-emission models by 2035.
The pledge is an embrace by the automaker of emission-reduction goals set by California.
The state is one of the largest markets for vehicles in the US and announced plans in September to ban sales of gasoline-powered cars and trucks by 2035. GM's target for achieving company-wide carbon neutrality is 10 years ahead of rival Ford Motor’s goal.
The company's stock rose as much as 7.4pc on the news.
GM's initiative is part of chief executive Mary Barra's strategy to take on Tesla’s leadership in electric vehicles and change the Detroit company's image as a builder of gas-guzzling, carbon-spewing trucks and SUVs. Barra already has committed GM to spending $27bn (€22bn) to build 30 electric vehicles by 2025.
"General Motors is joining governments and companies around the globe working to establish a safer, greener and better world," Ms Barra said in a statement. "We encourage others to follow suit and make a significant impact on our industry and on the economy as a whole."
GM will have to convert every model it sells to run on battery power or possibly hydrogen to meet its target. It aims to lower the price of some electric vehicles to make them accessible to more new-car buyers.
"Our focus will be offering zero-emission vehicles across a range of price points," Dane Parker, GM's chief sustainability officer, said in a call with reporters. "We're going to need to have products that appeal to all of our consumers, products they want and products that they can afford."
A big challenge for GM is staying profitable as it transitions to lower-margin electric vehicles.
Currently the gas-guzzling pickups and SUVs it's known for make up the majority of GM's income. Company President Mark Reuss has said the cost of GM's Ultium battery pack is coming down and its electric vehicles will be profitable.
UBS said in a report published last year that most global carmakers will be able to phase out their carbon emissions by 2040.
"We believe the transportation sector can be almost entirely decarbonized by 2040," the report said. "Why? New technologies have breakthroughs enabling them to start providing value at a reasonable cost, and saving energy has a feel good factor attached to it."
GM plans to use renewable energy for all of its plants and buildings globally by 2035. That's five years faster than the company previously targeted.
Ms Barra's move shows how the company's strategic plans have been shifting rapidly.
Four months ago when California Governor Gavin Newsom announced his ban on gasoline-fueled cars starting in 2035, Ford was quick to issue a statement praising the step.
GM at that time backed ex-president Donald Trump who wanted to weaken rules.