ExxonMobil reported a profitable fourth-quarter Tuesday to conclude a strong comeback year in 2021 on higher oil prices amid recovering energy demand.

The oil giant reported annual profits of $23 billion last year compared with a loss of $22.4 billion in 2020 when demand was dented by the Covid-19 lockdowns. High oil prices helped boost results again during the quarter, although increased costs cut into gains in some operations.

"Our effective pandemic response, focused investments during the down-cycle, and structural cost savings positioned us to realize the full benefits of the market recovery in 2021," said Chief Executive Darren Woods.

In the fourth quarter, ExxonMobil's upstream business benefited from higher prices in oil and natural gas, which surged 63 percent compared with the third quarter.

The company also benefited from a profitable run in its downstream business in a reversal from last year's fourth quarter, as well as increased earnings in chemicals.

ExxonMobil reported $23 billion in profits in 2021 in a reversal from a money-losing year in 2020
ExxonMobil reported $23 billion in profits in 2021 in a reversal from a money-losing year in 2020 AFP / Logan Cyrus

However, ExxonMobil said profits in its European refining operations were limited somewhat by higher energy prices. The company also flagged higher feed and energy costs as a drag in its chemical business.

On Monday, ExxonMobil announced it was combining its chemical and downstream businesses as it enacts $6 billion in cost savings through 2023. The company is also shifting its corporate headquarter to Houston from Irving, Texas near Dallas.

Shares rose 1.5 percent to $77.07 in pre-market trading.