Police arrested two people Saturday during the largest protest in recent memory in London, Ont., which pitted anti-Islam groups against counter-protesters.

Up to 500 people gathered in front of City Hall during the two-hour event, police estimated.

Emotions ran high, with shoving and yelling. A large police presence kept the sides apart.

A group called the Patriots of Canada Against the Islamization of the West (PEGIDA) had organized the rally on social media. Other far-right groups — including one called the Three Per Cent — had supporters there. They were wearing camouflage and black flak jackets.

Most of the people at City Hall were opposed to PEGIDA​. Counter-protesters appeared to outnumber PEGIDA supporters about 10 to one.

Tense moments here with two side getting heated <a href="https://t.co/cL4XN3MFSn">pic.twitter.com/cL4XN3MFSn</a> —@CBCLondon

One man was taken into custody after allegedly punching a counter-protester who had pushed a sign toward his face.

Police said a second person was arrested for a breach of peace. As of Saturday afternoon, no charges had been laid.

The standoff lasted about two hours, until PEGIDA supporters left.

Police study hate groups

London Police Supt. Chris Newton said authorities have been doing their homework on extremist groups.

"It's certainly a significant safety concern when you have large numbers and especially when there are two opposing points of view," said Newton.

"Especially given the political climate we are in, especially given some of the incidents down south which are certainly impacting people's perspectives up here."

Here's how peace protestors respond when anti-Islamic group tries to talk <a href="https://t.co/fUj5Rt0a3G">pic.twitter.com/fUj5Rt0a3G</a> —@CBCLondon

Jenny Hill, who would only say that she was from southwestern Ontario, was one of the PEGIDA supporters in London.

"We are here to give information about what is happening in our mosques here, what is happening in our universities, and the encroachment of Islam in our society," said Hill.

Len Boksman came out to join the counter-protest.

"There have been hate groups in London for a long period of time. This is not something new," said the long-time London resident.

"I think all over the world, there's been an awakening of the right and it's scary. I think everybody should stand up."

Protest over in <a href="https://twitter.com/hashtag/LdnOnt?src=hash">#LdnOnt</a> as groups promoting anti-immigration goes home. <a href="https://t.co/RgiuMznDxZ">pic.twitter.com/RgiuMznDxZ</a> —@CBCLondon

PEGIDA has its roots in a far-right political movement in Germany.

Before the rally, there had been a strong signal from the London community that hatred and racism would not be tolerated.

This week, London's city council passed a motion affirming that activities that promote hate would be banned in the city.

Several local politicians joined the counter-protesters on Saturday.