Owing to its intervention in the Syrian crisis, Russia is making a powerful comeback in the Arab world. In its efforts to pursue such a return, after years of being sidelined by Western powers, it is also playing a larger role in Libya.

In light of this, Moscow has conspicuously supported Marshal Khalifa Haftar, the strongman in eastern Libya, deploying Russian Special Forces to bases in western Egypt, near the Libyan border, to back his forces, and dispatching combatants from Russian private security companies to areas under Haftar’s control. Russia has been involved in other ways as well. It welcomed Libyan political figures, among them Haftar, to Moscow in 2016, while in January 2017 it invited Haftar to visit the Russian aircraft carrier Admiral Kuznetsov while the vessel was on its way back from Syria. In March 2017, Russia also received Fayez al-Sarraj in Moscow. Sarraj, a rival of Haftar, heads the United Nations-backed and internationally recognized Presidential Council based in Tripoli. In addition, the Russians have printed $3 billion worth of banknotes on behalf of the eastern Libyan authorities in Tobruk, to the dismay of the Central Bank based in Tripoli.

Those initiatives have affected internal power relations in a country shattered by civil war since 2014. That’s when Libya saw the establishment of two rival governments, leading to a sharp escalation in violence and the paralysis of state institutions, impacting negatively on prospects for a settlement of the Libyan crisis. And yet, whether Russian actions constitute part of a grand strategy that aims to confirm that Russia is a key international player remains questionable. In reality, Moscow has made opportunism a cornerstone of its behavior. Stepping into the Libyan conflict has served its ambitions in the Middle East and the Mediterranean, fitting into broader efforts to reassert Russia’s international role.

Indeed, Russia has mostly benefited from the mistakes and contradictions of European states and the United States in Libya. Their decision to depose the Libyan leader Mo‘ammar al-Qaddafi in 2011 was viewed by Russia as an affront to its interests. Western countries have created spaces for Russia to return to Libya thanks to their failure to stabilize the country after the conflict in 2011, as well as their focus on migration control and fighting terrorism, not to mention their deepening rivalries, mostly between France and Italy. The desire of the United States to avoid deep involvement in the country has only given Moscow more latitude to pursue its goals.

In a context of exacerbated regional rivalries, Libyan warring groups have also chosen to involve Russia more. For instance, Haftar has worked hard to secure Russian assistance to curb Turkish and Qatari influence in Libya, while also benefiting from good Russian relations with Egypt and the United Arab Emirates. However, Russia is not exclusively betting on Haftar. It has also maintained relations with the UN-backed Government of National Accord and with representatives of the city of Misrata in western Libya. This has potentially offered the Kremlin a central position in negotiating an overall Libyan settlement—just as its coordination with Turkey has done in Syria.

Russia has explained its engagement in Syria and Libya as a necessary step in fighting terrorism. In this regard, its greater involvement in Libya has helped restore its image as a great power, while making Russia indispensable in the search for a political settlement that could stabilize the European Union’s southern neighborhood. Moscow’s intervention in Libya is bound to put even more pressure on the EU to cooperate with Russia to stabilize Libya, in order to keep migration flows under control. This also may feed divisions among European states over the approach to Moscow, with some countries even tempted to make concessions over Ukraine and economic sanctions imposed on Russia following its annexation of Crimea.

Second, Russian engagement in Libya is driven by both short- and long-term economic interests, given that the country holds important deposits of oil and gas. Moscow remains hopeful that it can recover the losses of $4 billion in oil and gas exploration and infrastructure contracts that were signed before the fall of the Qaddafi regime. Down the road, Russia’s involvement could also help consolidate Moscow’s position in the energy markets and help keep oil prices high. Because Russia is greatly dependent on oil revenues, it has sought to reduce production and maintain high prices, the principal aim of a deal agreed with Saudi Arabia in December 2016. Greater sway over the energy markets would give Russia a larger geostrategic role in the Middle East and North Africa, while allowing it to advance its economic interests and perhaps alleviate the impact of sanctions.

Finally, when the time comes to rebuild the Libyan state, its war-stricken energy facilities, and its deeply divided armed forces, Russia doesn’t want to be absent from the reconstruction process. Stepping into the Libyan conflict is a guarantee for Russia to play a role in the postwar era. As one Russian expert put it succinctly while talking about stakes in Libya and Syria, “The Kremlin considers that without Russia always means against Russia.”

While Russia is playing a heightened role in Libya, having economic, and political interests there hardly constitutes a grand strategy in the country. Libya constitutes a terrain to advance Russia’s ambitions to be a key international player, amid the failure of Western countries to advance a common agenda in the country. Russian behavior in Libya exemplifies how Moscow has been able to reverse years of marginalization in the Arab world, despite relatively limited means.