An oil refinery of Essar Oil, which runs India's second-biggest private-sector refinery, seen in Vadinar. Thomson Reuters A multibillion-dollar Russian deal to buy the Indian refiner Essar was nearly sunk at the 11th hour by a rival bid from Saudi Arabia as the two oil superpowers vie for supremacy across the world.

The deal between Essar and a consortium led by the Kremlin oil giant Rosneft appeared dead in the water two months ago after the Saudi state energy firm Aramco weighed in, according to seven Russia, India, and Saudi-based industry sources familiar with or involved in the negotiations.

It was salvaged because of the involvement of Russian President Vladimir Putin and Indian Prime Minister Narendra Modi, who were keen for it go through, and after the consortium agreed to pay $13 billion — more than double what Rosneft had initially valued Essar at, sources told Reuters.

This made the refiner the biggest-ever foreign acquisition in India and Russia's largest outbound deal.

The tussle for Essar — a state-of-the-art plant in the world's fastest-growing fuel market — illustrates the growing battle for oil markets between Russia and Saudi Arabia, the world's two largest crude exporters.

It also sheds light on the challenges OPEC member Saudi Arabia and non-OPEC Russia, which are also fighting a proxy conflict in Syria's civil war, will face in trying to clinch a global agreement to limit output growth to prop up oil prices.

Indian Prime Minister Narendra Modi with Russian President Vladimir Putin at the signing of joint documents following the BRICS leaders meeting at the BRICS/SCO Summits. Getty Images The full details of how the Essar deal was struck remain unclear. Two industry sources said it was rescued thanks to the involvement of Putin and Modi, while three other sources said Rosneft had simply outbid Saudi Aramco.

Officials in Modi's office declined to comment, while Putin's spokesman, Dmitry Peskov, denied there was any Kremlin intervention in the deal.

"Naturally, we defend the interests of our companies — of course we lobby for them, especially on such large deals," Peskov said, adding that in the case of Essar "there were no orders from the Kremlin."

"It was a corporate decision by Rosneft to gain synergies via cooperation with India," he said.

Rosneft and Saudi Aramco declined to comment.

Essar said it had held discussions with several potential buyers but had gone with the Rosneft consortium because their offer was considered the most attractive. It denied there was any intervention from Putin or Modi.

Showdown

Rosneft boss Igor Sechin is keen to buy refining assets around the world to guarantee outlets for Russian oil. He had been negotiating since 2014 to buy 49% of Essar from its owners, Indian brothers Ravi and Shashi Ruia, and the two parties had been in exclusive talks since July 2015 when a preliminary deal was signed.

Workers next to a logo of Russia's Rosneft oil company at the central processing facility of the Rosneft-owned Priobskoye oil field outside Nefteyugansk. Thomson Reuters While the exact amount Rosneft was prepared to offer for the stake at that stage is unclear, Russian and Indian industry sources said it valued the whole of Essar at about $5.7 billion.

But it became apparent that there were problems with the deal in early September, when Sechin traveled to India to meet the Ruia brothers, flying from Hangzhou, China, where he had been part of Putin's G-20 summit delegation.

Sechin walked into the meeting with the Ruia brothers soon after landing in India at 1 a.m., determined to close the deal, according to sources briefed on the discussions.

As the meeting started, one of the brothers told Sechin the deal process had been going on for too long, the exclusivity period had expired in July and Essar was now talking to other parties.

Those other parties included Saudi Aramco, he said.

According to the sources familiar with how the meeting unfolded, Sechin responded by saying that if Essar walked away from the deal, it risked losing Russian financial and oil-supply support.

The Ruia brothers then said the talks with Rosneft were over and called an abrupt end to the meeting.

"People started leaving the room, embarrassed," one of the sources said. Another source said the Essar management had drafted a statement to say the deal with Rosneft was off.

Storage tanks of an oil refinery of Essar Oil seen in Vadinar. Thomson Reuters

Rosneft and Essar declined to comment on what transpired at the meeting or on whether such a statement had existed. Sechin and the Ruia brothers could not be reached for comment.

Three Saudi-based sources familiar with details of talks between Essar and Saudi Aramco said the firm was seriously considering buying Essar. One of the sources said Aramco was prepared to pay up to $9 billion for all or most of the refiner.

Aramco declined to comment on whether it had made a bid.

Too big to fail

In the end, however, the Rosneft-Essar deal proved to be too big to fail.

For India, a deal collapse or a delay because of talks with another party would set back Modi's drive to clean up India's $140 billion mountain of bad debt given Essar's multibillion-dollar debts to local and foreign banks after years of rapid expansion.

For Russia, the deal in the huge Indian market represented an important milestone in building a global oil empire despite Western sanctions imposed on Russia over its actions in Ukraine.

Facing the Saudi competition, Rosneft formed a consortium that bought 98% of the refiner plus a fuel terminal for $13 billion. The Kremlin oil firm bought 49% — below the 50% level that would have fallen foul of Western sanctions— with the Swiss trading house Trafigura and the Russian private investment group UCP buying the other 49%.

According to the Indian and Russian industry sources, Rosneft and Essar returned to the negotiating table within days of the spat in early September, and the deal was finally struck.

Putin visiting a Rosneft refinery in the Black Sea town of Tuapse in southern Russia in 2013. Alexei Nikolskyi/RIA Novosti/Kremlin/Reuters One of the sources said there was a fierce battle between Essar and Rosneft over the terms. They said the Russian-led consortium was forced to outbid the Saudi offer, which they said comprised a combination of cash, long-term low-interest credit, and oil supplies.

Trafigura declined to comment on how the deal came together, while UCP did not reply to a written request asking for comment. Washington said the deal did not violate sanctions.

The deal was signed in Mauritius on October 14, a day before a formal announcement on the sidelines of a BRICS summit in Goa where Putin and Modi met. The leaders also oversaw the signing of a raft of other transactions including India agreeing to pay $5 billion for Russian long-range air-defense missile systems.

Two industry sources said the Essar deal had first been discussed by Putin and Modi as far back as May 2014 on the sidelines of the St. Petersburg Economic Forum, Russia's main investor show.

It was unclear what form — if any — high-level government intervention might have taken after the September dispute.

But the two sources said that without political will in Moscow and New Delhi, an agreement could not have been struck.

"Putin and Modi saved that deal," one said.

(Additional reporting by Rania el Gamal; Writing by Dmitry Zhdannikov; Editing by Pravin Char)