LONDON (AP) - British energy firm BP reported record annual earnings Tuesday, fueling demands that the U.K. government boost taxes for companies benefiting from the high price of oil and natural gas after Russia's invasion of Ukraine.

London-based BP said underlying replacement cost profit, which excludes one-time items and fluctuations in the value of inventories, jumped to $27.7 billion in 2022 from $12.8 billion a year earlier. That beat the $26.8 billion BP earned in 2008, when tensions in Iran and Nigeria pushed world oil prices to a record of more than $147 a barrel.

BP also increased its quarterly dividend by 10% and announced plans to buy back an additional $2.75 billion of stock from shareholders.

But the good news for BP shareholders is likely to be tempered by the public fallout, particularly in its home country. High oil and gas prices have hit Britain hard, with double-digit inflation fueling a wave of public-sector strikes, soaring food bank use and demands that politicians expand a tax on the windfall profits of energy companies to help pay for public services.

Ed Miliband, the opposition Labour Party's spokesman on climate issues, called on the U.K. government to bring forward a “proper” windfall tax on energy companies.

“It's yet another day of enormous profits at an energy giant, the windfalls of war, coming out of the pockets of the British people,″ Miliband said.

Similar censure was directed at London-based Shell last week, when it said annual earnings doubled to a record $39.9 billion last year.

Bumper profits for energy companies worldwide have sparked demands that the fossil fuel industry do more to offset high energy bills even as they cut climate-damaging carbon emissions. U.S.-based Exxon Mobil posted record earnings of $55.7 billion last week.

Last year, Britain approved a 25% windfall tax on earnings from oil and gas produced in the U.K., with the levy increasing to 35% in 2023. Opposition leaders have criticized the government for allowing energy companies to reduce the tax by investing in the U.K.

BP said it took a charge of more than $1.8 billion last year to cover the new U.K. tax.

The company also took charges of $25.5 billion as the result of its decision to exit its investments in Russia after the invasion of Ukraine.

After including one-time items and fluctuations in the value of inventories, BP posted a net loss of $2.49 billion for 2022, compared with net income of $7.57 billion the previous year.

BP on Tuesday said it would boost investment in renewable energy, hydrogen and electric vehicle charging as well as its oil and gas businesses, plowing an additional $8 billion into the two segments through 2030.

The investments will push oil and gas production to about 2 million barrels of oil equivalent a day in 2030. While the new target is 25% lower than in 2019, BP previously planned to cut production by 40%.

“We will prioritize projects where we can deliver quickly, at low cost, using our existing infrastructure, allowing us to minimize additional emissions and maximize both value and our contribution to energy security and affordability,” chief executive Bernard Looney said in a statement.

Energy prices soared after the invasion of Ukraine. Brent crude, a benchmark for global oil prices, averaged $101.32 a barrel last year, 43% higher than in 2021. The average wholesale price of natural gas in Britain jumped 76%.

Prices have dropped in recent months, with Brent crude averaging $88.87 in the fourth quarter.

“The question becomes, what will they do with record profits and operating cash flow? Governments are already questioning record profits from other peer global energy companies,” said Gianna Bern, an oil expert and professor of finance at the Mendoza College of business at the University of Notre Dame. “In an environment of record inflation and gas prices for the consumer, global energy companies will be compelled to reassess the cost and availability of energy for all.”

Alice Harrison, fossil fuels campaign leader at environmental advocacy nonprofit Global Witness, said BP's profits were made “on the back of three global crises” - the war in Ukraine, the energy crisis and climate breakdown.

“For those struggling, these mammoth profits will be a bitter pill to swallow,” Harrison said. “There are no two ways about it - BP is richer because we're poorer.”