Police brought in reinforcements as violence hopped from slum to slum in scenes reminiscent of some of the bloodiest days of apartheid. Most of the victims have been immigrants from Zimbabwe and elsewhere in Africa living in squatter camps.
Archbishop Desmond Tutu made an impassioned plea Monday for the violence to end. "Please stop. Please stop the violence now," he said in a statement. "These are our sisters and brothers."
Tutu said that when South Africans were fighting apartheid, they were supported by people worldwide. "We can't repay them by killing their children," he said. "We can't disgrace our struggle by these acts of violence."
President Thabo Mbeki reiterated his call for an immediate stop to the attacks, saying "nothing can justify it" and that police will get to the "root of this anarchy."
South Africans are struggling to buy food as prices rise amid stubbornly high unemployment, and many complain the government hasn't worked fast enough to build houses, schools and hospitals for the black majority. Foreigners were attacked because they are seen as competing for scarce resources - and because they were the closest targets at hand for the poor.
Leyton Salaman, a 35-year-old tiler from Malawi, said the trouble started slowly in Ramaphosa, a collection of shacks east of Johannesburg. A few foreigners were beaten Friday, then shacks were set afire. When the killing started Sunday, Salaman and hundreds of others fled to neighboring Reiger Park, where he sat in a church yard Monday.
"These people, they said, `You are taking our jobs,"' said Salaman, who has lived in South Africa for eight years. "Now they just come and take our things."
Police spokesman Govindsamy Mariemuthoo said 22 people had been killed since the violence broke out last week. Mariemuthoo said more than 200 people had been arrested on charges including murder, rape and robbery.
Mariemuthoo said police reservists and officers from other regions were being called in to help. The South African Red Cross and other aid groups appealed for funds to care for the hundreds of displaced.
Some victims were set afire. Jonathan Whittal, a humanitarian affairs officer with Medecins Sans Frontieres, said his group had seen cases of rape as well as gunshot and other wounds.
"The violence is extreme," Whittal said, calling for a more coordinated humanitarian response. He also said security for immigrants would remain a concern even after the current outbreak is extinguished and the underlying causes would have to be addressed.
The violence would likely add to South Africa's image as a crime center - it has a murder rate of more than 50 a day - just as it prepares to host the 2010 soccer World Cup.
While still high, crime rates in South Africa have been slowly dropping. Many South Africans, though, say they don't believe the official statistics and feel crime really is rising - one measure of the public's distrust of the government.
The Nelson Mandela Foundation was among the organizations that called for calm, noting that the former president had sponsored projects aimed at helping immigrants integrate into South African communities.
In a statement, the foundation repeated a plea that South Africa's first black president made during an outbreak of xenophobic violence in 1995: "We cannot blame other people for our troubles."
Zimbabwean Gina Themba nursed her 2-week-old daughter on the floor of a room at a police station in Johannesburg on Monday. She said neighbors she had lived next to the past three years broke into her house overnight and demanded she leave. She said she did not understand why.
Such scenes were repeated in pockets across the Johannesburg region. Foreigners fled to police stations, churches and community halls. At one police station-turned-refugee camp, a young man wandered with a loaf of bread and a knife, selling slices for about 15 U.S. cents each, in a display of the kind of immigrant entrepreneurship that has sparked resentment.
Vincent Williams, head of an immigration research project of the independent Institute for Democracy in South Africa, said accusations that immigrants take jobs from natives or are responsible for crime are heard around the world.
He said it was rare for such sentiment to erupt into sustained violence, but this was not the first time it has done so in South Africa. The last serious outbreak was just after apartheid ended in 1994.
"We've known for quite awhile that levels of xenophobia in South Africa are high," Williams said. He said speculation about the reasons has touched on the isolation created by apartheid as well as fears the institutionalized racism of the past has left even black South Africans suspicious of black foreigners.
Zimbabweans, Malawians, Mozambicans and others from elsewhere in Africa have been the main targets of the violence.
Some South Africans were moved to help foreigners, dropping by the impromptu shelters with food, clothing, blankets and other donations. Lisa Letsoso, an 18-year-old South African living in the Ramaphosa squatter district, was up all night working with church groups distributing aid to people who had fled to Reiger Park.
"The South Africans are fighting the foreigners. Now the foreigners are fighting back," Letsoso said. "Everyone is suffering."