Head of the Austrian Freedom Party (FPOe) Heinz-Christian Strache, right, celebrates after regional elections in Vienna on Oct. 11, 2015. (REUTERS/Leonhard Foeger)

Austria's Social Democrats won a narrow victory in local elections in Vienna on Sunday, withstanding a challenge from the far-right Freedom Party. The contest for governance in the Austrian capital had been spurred by the ongoing refugee crisis in Europe, which has seen thousands of Syrian refugees and other migrants enter Austria.

Polls ahead of the election suggested that mounting anti-immigration and anti-refugee sentiment could have led to the Socialists losing hold of the city — dubbed "Red Vienna" for its traditional political bent — for the first time since the end of World War II. But that didn't come to pass. The Socialists won nearly 40 percent of the vote, a dip of 5 percent from the previous elections half a decade ago.

The Freedom Party, led by the controversial former dentist Heinz-Christian Strache, won a considerable 32 percent of the vote, a record result despite the defeat. The party's surge in the polls was a source of genuine alarm for many in Vienna. Strache has championed building a wall along Austria's border akin to the fortified fence erected by Hungary's right-wing government.

Not unlike other xenophobic populists, Strache and his party painted the refugee influx as a gateway for criminals and terrorists. "We have a Christian culture, and we want to keep a Christian culture for our children," he said. The city of 1.8 million people expects to take in 12,000 asylum seekers this year. In the past, Strache has brushed off charges of racism and bigotry by arguing that he "eats kebabs."

"Will Vienna be the first democratic western metropolis with a right-wing party in the majority?" Christian Rainer, publisher of the influential Profil news magazine, told Politico Europe before the election. "The chances are 50-50. That alone is a 100 percent catastrophe."

Despite losing, Strache hailed what his party had accomplished. "No one will be able to belittle our success today," he told an Austrian broadcaster.

The refugee crisis has galvanized far-right parties elsewhere in the continent. Despite the rather courageous leadership of German Chancellor Angela Merkel, who favors allowing hundreds of thousands of Syrian refugees into Europe, anti-immigrant and anti-Muslim forces in Germany have sought to capitalize on the moment. In the eastern city of Dresden this week, anti-Islam protesters even erected a set of gallows for Merkel.

In the Netherlands, demagogic far-right leader Geert Wilders has noisily protested any measure to offer sanctuary to refugees. During a speech to parliament last month, he warned of an "Islamic asylum tsunami" and labeled the refugees "testosterone bombs" who "threaten our girls." This ugly rhetoric was repudiated by his opponents and critics but has not hurt his political chances. Recent polls showed Wilders's PVV party as potentially winning one of the country's biggest blocs of seats in parliament.

The theme is repeated in other corners of Europe, from Nordic nations to Eastern Europe and the Balkans. But as the result in Vienna still shows, the continent's voices defending multiculturalism and tolerance are still as loud, if not louder.