HOUSTON — Exxon Mobil is abandoning its joint exploration ventures with the Russian oil company Rosneft, retreating from what was one of its most promising investments until Western sanctions got in the way.

During the early years of the Obama administration, when there was a brief warming of relations, Exxon Mobil signed an exploration deal with the Russians. Exxon and Rosneft, which is only half-owned by the Russian government but state-run, agreed to invest $3.2 billion to search for oil in deepwater fields in the Arctic and elsewhere.

After Russia annexed Crimea from Ukraine in 2014, the United States and its European allies applied several sanctions on Moscow, eventually freezing Exxon’s investments.

In a regulatory filing on Wednesday, Exxon said that it had decided late last year to abandon the ventures this year and would take an after-tax loss of $200 million. “The corporation and its affiliates continue to comply with all applicable laws, rules and regulations,” the company said.