WASHINGTON — President Trump traveled to Detroit on Wednesday to announce a rollback of stringent fuel economy standards for cars and trucks that were put in place by the Obama administration — a welcome message to American automakers but one that could slow the push for a new generation of efficient vehicles.

The fuel-economy rules, aimed at cutting heat-trapping carbon dioxide, were one of the two main pillars of President Barack Obama’s climate change legacy. Put forth in 2012, they would have required automakers to nearly double the average fuel economy of new cars and trucks to 54.5 miles per gallon by 2025, forcing automakers to speed development of highly fuel-efficient vehicles, including hybrid and electric cars.

The rules have been widely praised by environmentalists and energy economists for reducing the nation’s dependence on foreign oil and its greenhouse pollution. If put fully into effect, the fuel efficiency standards would have cut oil consumption by about 12 billion barrels and reduced carbon dioxide pollution by about six billion tons over the lifetime of all the cars affected by the regulations.

That would have been a little more than the amount of oil consumed and carbon pollution produced by the United States in a year, according to the Environmental Protection Agency.