Following Russia’s invasion of Ukraine, British oil and gas giant BP will dump 19.75% of its stake in the Russian-controlled oil company Rosneft.

On Sunday, BP announced plans to offload its stake after operating in Russia’s reserves for over three decades. BP CEO Bernard Looney and former chief executive Bob Dudley are also resigning from Rosneft’s board, effective immediately.

“I have been deeply shocked and saddened by the situation unfolding in Ukraine, and my heart goes out to everyone affected. It has caused us to fundamentally rethink bp’s position with Rosneft,” Looney said in a statement.

Rosneft provides about half of BP’s gas and oil reserves and accounts for a third of its production.

The decision to dump its stake with the Russian oil giant will cost up to $25 billion. BP predicts its first-quarter results in May will report a material non-cash charge.

Although the company will take a financial hit, BP chairman Helge Lund stated the company needed to reconsider its relationship with Rosneft.

“This military action represents a fundamental change,” Lund said in a statement. “It has led the BP board to conclude, after a thorough process, that our involvement with Rosneft, a state-owned enterprise, simply cannot continue.”

The decision comes after BP faced pressure to offload its stake. British officials previously accused Rosneft of provoking the Kremlin’s invasion into Ukraine.

However, BP doesn’t believe the costly decision will not have any short and long-term effects on its financial targets. The company is in the process of moving away from gas and oil for renewable energy and low-carbon fuels.

Although BP will distance itself from Russia, the company did not provide details on how it plans to detach from Rosneft.

BP returned to profit as oil prices recovered
BP returned to profit as oil prices recovered AFP / Glyn KIRK