JOHANNESBURG — South African police clad in riot gear on Wednesday forcibly broke up a group of refugees who had occupied a square in central Cape Town for three weeks, pleading for help in leaving a country plagued by anti-immigrant violence.

Photos and videos of the raid showed police officers carrying away some of the protesters, their legs and arms dragging on the road, before the police shoved them into armored vehicles and vans. The police aimed water cannons at crowds, according to some local news reports, and some protesters accused the officers of firing rubber bullets at them, showing the welts on their bodies to journalists.

The police said about 100 people were arrested after they failed to heed the call to disperse from the area they have occupied since Oct. 8. Some 300 refugees have camped outside the offices of the United Nations High Commissioner for Refugees on St. George’s Mall, a square known for hotels and a popular tourist market.

They have called on the refugee agency to either help them return to their home countries, or help them travel to safer countries following the latest outburst of violence against immigrants.