(Corrects name of professor to Mudde instead of Muddle, adds Erdogan's first name)
By Toby Sterling and Anthony Deutsch
AMSTERDAM (Reuters) - Dutch centre-right Prime Minister Mark Rutte scored a resounding victory over anti-Islam and anti-EU Geert Wilders in an election on Wednesday, offering huge relief to other governments across Europe facing a wave of nationalism.
Rutte declared it an "evening in which the Netherlands, after Brexit, after the American elections, said 'stop' to the wrong kind of populism."
Rutte received congratulatory messages from European leaders and spoke with some by telephone. The euro gained as the results pointed to a clear Rutte victory.
Experts said Rutte won on a mix of factors, not all of which may apply to France, whose political establishment faces a challenge from a far-right populist Marine Le Pen next month.
Moreover a number of parties including Rutte's VVD and the third place Christian Democrat party (CDA) have already adopted most of Wilders' anti-immigration platfom, if not his fiery anti-Islam rhetoric.
"Rutte profited from moving to the right, but also from Wilders having radicalized a lot over the last years and being invisible in the campaign," said Cas Mudde, associate professor at the University of Georgia, referring to Wilders' decision to forego election debates until the final week of the campaign.
"On top of that, Turkish President (Tayyip) Erdogan gave (Rutte) a beautiful gift."
Rutte got a last-minute boost from a diplomatic row with Turkey, which allowed him to take a tough line on a majority Muslim country during an election campaign in which immigration and integration have been key issues.
Wilders said he had not achieved the electoral victory he had hoped for but was ready to offer tough opposition.
"I would rather have been the largest party.... but we are not a party that has lost. We gained seats. That's a result to be proud of," Wilder told journalists.
With around 95 percent of votes counted, Rutte's VVD Party won 33 of parliament's 150 seats, down from 41 at the last vote in 2012. Wilders' Party for Freedom (PVV) was second with 20, the CDA and centrist Democrats 66 tied for third with 19 each, data provided by the ANP news agency showed.
At 78 percent, turnout was the highest in a decade in an election that was a test of whether the Dutch wanted to end decades of liberalism and choose a nationalist, anti-immigrant path by voting for Wilders and his promise to "de-Islamicise" the Netherlands and quit the European Union.
The result was a relief to mainstream parties across Europe, particularly in France and Germany, where right-wing nationalists hope to make a big impact in elections this year, potentially posing an existential threat to the EU.
Le Pen is set to make France's presidential election run-off in May after a first round in April, while eurosceptic, anti-immigrant Alternative for Germany is likely to enter the German federal parliament for the first time in a September election.
German Chancellor Angela Merkel's chief of staff, Peter Altmaier, could not restrain his joy, tweeting: "The Netherlands, oh the Netherlands you are a champion!..... Congratulations on this great result."
France's Foreign Minister Jean-Marc Ayrault tweeted: "Congratulations to the Dutch for stemming the rise of the far-right."
The exit polls helped the euro rise to its highest against the dollar since Feb. 7.
But Mabel Berezin, professor of sociology at Cornell University in the United States, said defeat for Wilders, who has been in parliament for nearly two decades, should not be considered a sign that European populism is waning.
"He does not represent a populist wave. Rather, he is part of the political landscape and how his party fares does not tell us much about European populism," she said.
"The real bellwether election will be Marine Le Pen's quest for the French presidency, starting April 23 – that is where the populist action is and that is what we should be focusing upon."
The spat did not hurt the chances of Denk, a party supported by Dutch Turks, which looked set to win three seats, becoming the first ever ethnic minority party in parliament, in a possible sign of deepening ethnic division.
But, while Rutte averted what in the early stages of the campaign looked like a possible victory for Wilders, years of austerity pushed down his share of the vote. His junior partner in the outgoing coalition, Labour, suffered its worst ever result, winning just nine seats, down from 38 last time.
That means it will likely take months for Rutte to negotiate a ruling coalition, with at least three other parties needed to reach a majority in parliament.
Wilders declared in a Tweet: "Rutte has not seen the last of me yet!!"
His result is well down from his 2010 high of 24 seats while support for the two most pro-EU parties, the progressive D66 and GreenLeft, was way up.
Additional reporting by Stephanie van den Berg, Anthony Deutsch and Philip Blenkinsop; Writing by Robin Pomeroy; Editing by Catherine Evans, James Dalgleish and Lisa Shumaker