Dutch judges on Friday upheld Geert Wilders' conviction for collectively insulting Moroccan people at a rally, in what the firebrand far-right leader branded a "political trial" by a "banana republic."

The appeals court threw out, however, a charge of inciting discrimination over a 2014 gathering where the peroxide-blonde Wilders asked supporters if they wanted "fewer or more Moroccans" and the crowd chanted "Fewer! Fewer!".

In a politically charged judgment ahead of elections next year, the judges decided not to punish Wilders, saying he had already paid the price because he needs constant personal protection due to death threats over his anti-Islam remarks.

A lower court had convicted Wilders -- whose Freedom Party is the second biggest in the Dutch parliament -- of both group insult and inciting discrimination in 2016 but he had appealed the verdict.

"The court considers it proven that Mr Wilders is guilty of group insult on March 19, 2014. The court will not impose any punishment or measure on him for this," judge J.M. Reinking said.

"He is acquitted of the other facts."

Wilders had framed the case as a free speech issue, as he has with previous controversial acts such as a competition for cartoons of the Prophet Mohammed, but judges rejected his arguments.

"The right to freedom of expression, especially that of a politician, does not preclude conviction in this case," they said.

Wilders reacted furiously after the case, saying he would appeal to the supreme court and warning that opponents such as Prime Minister Mark Rutte "should not cheer too soon".

"The Netherlands has become a corrupt country. Moroccans who set our cities and neighbourhoods on fire usually get away with it," he told reporters outside court.

Wilders said the Dutch justice minister had recently got away with breaking coronavirus distancing rules, "but the leader of the largest opposition party who has a question about Moroccans, where millions of Dutch agree, has been convicted, in a political trial."

Dutch far-right Freedom Party leader Geert Wilders says he will appeal to the supreme court
Dutch far-right Freedom Party leader Geert Wilders says he will appeal to the supreme court ANP / Remko de Waal

The trial had focused in particular on a statement made at a 2014 local government election rally in The Hague, when Wilders asked supporters whether they wanted "fewer or more Moroccans in your city and in the Netherlands".

When the crowd shouted back "Fewer! Fewer!" a smiling Wilders answered: "We're going to organise that."

Dutch police received 6,400 complaints about Wilders' comments.

While the appeals judges upheld the original conviction for "group insult", they said they had acquitted Wilders of incitement to discriminate because his comments were for political gain and had "not intended to encourage his public to do so."

The anti-Islam leader said on Twitter ahead of the verdict that it would decide if the Netherlands had "become a corrupt banana-republic."

Wilders lives in a safe house and has been granted 24-hour protection by the Dutch state because of death threats over his anti-immigration and anti-Islam comments.

His Twitter feed regularly pumps out anti-Islam comments and drawings, and he announced plans in 2018 for a cartoon competition of the Prophet Mohammed.

The move sparked angry protests among Muslims, particularly in Pakistan, but he cancelled after receiving threats against his life.

A day after he announced the cancellation, an Afghan man stabbed two American tourists at Amsterdam's main train station. The man, who said he wanted to "protect the Prophet Mohammed", was sentenced to 26 years in jail in October.

Wilders' profile has diminished recently with the populist Thierry Baudet and his Forum for Democracy party surging to a good showing in European elections last year.

However, he remains a key figure in Dutch politics, with Rutte having tacked to the right during the last elections in 2017 in a bid to keep Wilders out of power as populist parties surged in the wake of the 2016 Brexit vote and election of Donald Trump.