About 2,000 police officers were in place to prevent trouble, including reinforcements from other parts of Germany.
Protesters said some slogans against German Chancellor Angela Merkel.
Police said several thousand people turned out for the demonstration organised by Alternative for Germany(AfD).
AfD won 12.6% of the vote to enter Germany’s national parliament last year on anti-migrant and anti-establishment sentiment.