Ankara has warned the West it could “lose” Turkey unless it showed more support for the country and its president, Recep Tayyip Erdogan, a day after he met Russian counterpart Vladimir Putin to repair their damaged ties. Mr Erdogan has accused western capitals of failing to condemn last month’s failed coup, while criticising him for purging thousands of people who allegedly shared the coup-plotters’ views and for threatening to restore the death penalty in Turkey.

He has also lambasted the United States for refusing to immediately hand over Fethullah Gulen, the Pennsylvania-based Muslim cleric whom Ankara accuses of being behind the coup attempt.

The growing rift with the West, as well as fears over Syria and economic concerns, spurred Mr Erdogan to seek to restore relations with Moscow that were wrecked last November when Turkey shot down a Russian fighter jet over the Syrian border.

The sudden rapprochement between Turkey and Russia unnerved some officials in the EU and Nato, who fear the two autocratic and powerful leaders could cause trouble for the West on issues including Syria and refugees.

As Turkish diplomats and military and intelligence officials held talks in Moscow yesterday, foreign minister Mevlut Cavusoglu said his compatriots had lost confidence in the EU because it had “failed a test” over the coup.

“Let me say openly, this is because the EU adopted a favourable position to the coup [and] encouraged the putschists,” he said, without giving details. “Our relations with Russia are not a message to the West.

“We worked very hard to have good relations with Europe for 15 years. If the West one day loses Turkey – whatever our relations with Russia and China – it will be its own fault.”

Nato spokeswoman Oana Lungescu insisted the alliance’s secretary general, Jens Stoltenberg, had been quick to call Mr Erdogan “strongly condemning the attempted coup and reiterating full support for Turkey’s democratic institutions”. “Nato counts on the continued contributions of Turkey and Turkey can count on the solidarity and support of Nato,” she added.

Mr Putin said Russia would lift economic sanctions from Turkey and seek a “common approach” with Ankara to a Syrian conflict on which their positions have clashed .

Turkey still wants to see Syrian president Bashar al-Assad removed, however, while Russia continues to provide massive military support to his troops.

Mr Cavusoglu said Turkey wanted to establish a “strong mechanism” with Russia to find a solution for Syria, without explaining what this might entail. “We think similarly regarding the ceasefire, humanitarian aid and [the need for] political resolution in Syria. We may think differently on how to implement the ceasefire.”