ABUJA/JOHANNESBURG (Reuters) - South African companies MTN and Shoprite closed stores in Nigeria on Wednesday in the face of attacks targeting their premises in retaliation to similar violence in their home country.

Nigeria’s vice president is also boycotting an economic forum in Cape Town on boosting intra-African trade, the country’s foreign minister said, after days of rioting in South Africa aimed at foreign-owned businesses.

At a Shoprite supermarket on the outskirts of the Nigerian capital Abuja, hundreds of protesters tried to break into the premises, throwing stones, setting fire to tires and nearly overwhelming police protecting the site.

After police fired a barrage of teargas at the crowd, they dispersed, according to a Reuters witness.

The Nigerian division of telecom operator MTN said on Wednesday morning it would shut all stores and service centers in the country until further notice.

“The safety and security of our customers, staff and partners is our primary concern,” MTN Nigeria said in a statement. “MTN condemns any acts of violence, prejudice and xenophobia.”

Nigeria is MTN’s biggest market, with 58 million users in 2018 and accounts for a third of the South African group’s core profit.

Slideshow ( 7 images )

Nigerian Foreign Minister Geoffrey Onyeama on Wednesday implored people to stop attacking these businesses.

“These businesses, Shoprite, MTN and others, yes, they are South African,” he said at a press briefing.

“But these are subsidiaries in Nigeria owned by Nigerians. So, as attacks are made against Shoprite and other such institutions, it is actually the property owned by Nigerians within Nigeria and the people working there are Nigerians.”

“XENOPHOBIC VIOLENCE”

Shoprite said several stores in South Africa, Nigeria and Zambia were closed and extensive damage had been done to several supermarkets over the past 24 hours.

“The retailer is highly concerned about the acts of xenophobic violence against foreign nationals,” the grocer added in its statement.

Slideshow ( 7 images )

South African President Cyril Ramaphosa told officials and business leaders on Wednesday that he was committed to quelling attacks on foreigners.

The latest wave of unrest in South Africa has raised fears of a recurrence of violence in 2015 aimed at foreigners and in which at least seven people were killed. Before that, some 60 people were killed in a wave of unrest around the country in 2008.

Nigerian President Muhammadu Buhari said on Tuesday he was urgently sending a special envoy to meet with Ramaphosa to secure the “safety of (Nigerian citizens’) lives and property”.

Additionally, Nigeria’s Vice President Yemi Osinbajo won’t be going to the World Economic Forum’s Africa summit in South Africa, Onyeama said at his briefing. Osinbajo was slated to attend.

“Clearly with this climate, he and Mr. President have agreed that he should not go,” Onyeama said.

Nigeria is also considering recalling its ambassador to South Africa, he said.

South African police have yet to pinpoint what prompted the violence, which began on Sunday when protesters armed with makeshift weapons roamed the streets of Pretoria’s business district, pelting shops with rocks and petrol bombs and running off with goods.

The police have arrested almost 300 people and confirmed several deaths after the riots.