Russian President Vladimir Putin (R) shakes hands with Turkish President Recep Tayyip Erdogan during their joint press conference at the Kremlin in Moscow on April 8, 2019. (Photo by Alexander NEMENOV / AFP) (Photo by ALEXANDER NEMENOV/AFP via Getty Images)

Editor’s Note: Elmira Bayrasli is the Director of the Bard Globalization and International Affairs Program and the CEO of Interruptrr, a weekly foreign policy newsletter. The views expressed in this commentary are her own. Read more opinion on CNN.

CNN  — 

For Recep Tayyip Erdogan, Turkey’s longest serving ruler, Sunday’s upcoming election may be the end of a two-decade winning streak.

Elmira Bayrasli

Polls show that Erdogan, who has been at the country’s helm since 2003, first as prime minister and since 2014 as president, is in a tight race and vulnerable to defeat. 

This has made many in Brussels and Washington giddy — and hopeful that Turkey, a once reliable ally and partner turned spoiler, will rejoin the Western fold.

At the start of his rule, Erdogan, a pious Muslim who successfully governed Turkey’s largest city, Istanbul, in the 1990s, affirmed the country’s western orientation and ambition to join the European Union.

For the past decade, however, Erdogan, now 69, has not only adopted a more combative and unsavory tone towards the US and Europe – but more combative and unsavory friends.

At the top of that list is Russia’s President Vladimir Putin.

Putin won Erdogan over on the night of July 15, 2016. Following an attempted coup to unseat Erdogan, the Russian president called his Turkish counterpart and offered his country’s support.

The US president at the time, Barack Obama, called Erdogan four days later.

It helped feed the conspiracy narrative Erdogan’s government had long put forward — that the US, who refused to extradite the suspected coup plotter, the Islamic preacher Fetullah Gulen, was guilty of “dirty plots” against Turkey. It moved Moscow and Ankara closer together.

The following year, much to the chagrin of fellow NATO members, the Turkish government announced the purchase of a Russian-made air defense system, the S-400.

Fast forward to Russia’s full-scale invasion of Ukraine in February 2022, and Erdogan has refused to sanction or implement a flight ban on Turkey’s northern neighbor. Over the past few months, Ankara has also blocked Sweden’s application to NATO, claiming Stockholm supports Kurdish separatist militants who are a threat to Turkey.

If all of that were not enough to upset the West, before the devastating earthquake in Turkey and Syria this past February that killed nearly 60,000 people and displaced over a million, Erdogan had turned up threats against Greece in the Aegean. His mishandling of the disaster and subsequent revelations that he allowed developers to skirt construction regulations, brought him to heel and tone down any war rhetoric.

Still, it was not enough to change the eastern tilt of Turkish foreign policy. Whether Erdogan wins or loses, Ankara is unlikely to untangle itself from Moscow and turn back to the West.

To start, Turkey can’t afford it. The economy is mired in inflation. The Turkish lira is weak. Growth has stalled. The country needs to maintain its trade ties for its exports to the Middle East, Caucasus and Europe.

More importantly, it depends on tourism dollars and energy imports from Russia. Moscow has been supplying cash-strapped Turkey with natural gas, on credit. Especially if Erdogan loses, you can bet that Putin will press the new government to not only pay up, but to continue to be one of the few countries that engages with him.

Even if Erdogan is defeated, he will not simply disappear from public life. This is not just a matter of whether he would peacefully hand over power. Erdogan would be relegated to the opposition. In a bitterly polarized Turkey, that would continue to give him leverage.

In addition to the president, Turks will vote for representatives in parliament. Erdogan’s Justice and Development Party, known through the initials AKP, is expected to secure a significant bloc, if not a majority. That’s the pulpit Erdogan would use to attack the new government.

And attack he would. Erdogan’s popularity soars when he dials into Turkish nationalism and lashes out at what he has described as the country’s “opponents” — the PKK, the West, Israel, all working, as he claims, to undermine the Turkish Republic, which turns 100 in October.

Erdogan’s wide-reaching grip on the media would help with this. In power for 20 years, Erdogan has been able to crush a free press, turning it into a megaphone for his own use. Journalists who criticize the government are jailed. Media outlets largely operate under the control of Erdogan cronies. (The Turkish president has previously dismissed concerns about press freedom in his country).

Erdogan has also been able to shape Turkey’s institutions to his will. This includes the foreign ministry. In a recent report published by the Foundation for Defense of Democracies (FDD), author Sinan Ciddi notes that starting in 2009, the Erdogan government “began to appoint foreign service officers at both the junior and senior levels based on allegiance to the AKP/Erdogan line.” It enabled “nepotism, cronyism, and sycophancy with a huge disregard for impartiality and expertise.” (The Erdogan government has not commented on the accusations).

Get our free weekly newsletter

  • Sign up for CNN Opinion’s new newsletter.
  • Join us on Twitter and Facebook

    What does or can the West do? Allow Ankara to keep its distance. Washington and Brussels have to recognize that Turkey is a country literally and metaphorically at the crossroads. Not entirely in the West or the East, it is positioned to be both a difficult and useful partner.

    While Ankara may currently engage Moscow, it cannot completely spurn NATO or the EU either. Turkey’s success depends on economic growth, namely through exports and foreign investments. Hence, it willingly sold armed drones to Ukraine.

    Last summer, Turkey successfully brokered a deal between Russia and Ukraine to export grain out of Ukraine. Erdogan has long been eager to catapult Turkey to be a regional player and has been eager to bring the warring sides to negotiate peace. A strident Turkey, not completely aligned with the West and the gatekeeper to Russia and Ukraine’s only shipping outlet over the Black Sea, makes it a credible broker for both sides.

    That’s the role the West should cast for Turkey. It is a role the Turks, under Erdogan or otherwise, would have no choice but to play.