The revelation was made by acting Foreign Affairs minister Haruna Kasolo as the first group of 273 evacuees arrived at Entebbe International Airport late Thursday aboard a special Uganda Airlines charter flight.
Speaking after receiving the returnees, Minister Kasolo said government was deeply saddened by the deaths and had begun arrangements to repatriate the victims' remains.
"On a sad note, government regrets to report that three Ugandans lost their lives. Mr Wilbert Nuwamanya lost his life following an attack in KwaZulu-Natal Province. The second individual, who is yet to be identified, lost his life in Cape Town, while there is also a third victim. Government is making arrangements to repatriate their bodies," Kasolo said.
The returnees, many of whom said they fled with only the clothes they were wearing, broke into cheers as the aircraft landed at Entebbe, ending days of uncertainty after violent protests targeted foreign nationals and their businesses in parts of South Africa.
The evacuation follows a directive from President Yoweri Museveni ordering government agencies to rescue Ugandans affected by the violence.
The operation is being coordinated by the Ministry of Foreign Affairs, the Office of the Prime Minister, the Ministry of Internal Affairs, security agencies, the Ministry of Works and Transport, the Uganda High Commission in Pretoria and leaders of the Ugandan community in South Africa.
Government said all the chartered Uganda Airlines flights are being fully funded by the state.
Kasolo described the operation as evidence of government's commitment to protecting Ugandans abroad.
"The exercise is a testament to the seamless cooperation with our people in the diaspora," he said.
He added that government intends to organise a meeting between the returnees and President Museveni.
"To our returnees, we understand this is a difficult moment. We hope to secure an audience with the Head of State, President Yoweri Museveni, and we understand he is ready to meet you."
Kasolo also assured the evacuees that government would support their reintegration and encouraged them to contribute to Uganda's economic development.
"You are Ugandans, and we are ready to integrate you into Uganda's economic development," he said.
Moses Kibombo, President of the Confederation of Ugandans in Southern Africa (COUSA), praised the Uganda People's Defence Forces (UPDF) and the Chief of Defence Forces for supporting the rescue operation.
"The CDF assigned personnel from his office to support the rescue of Ugandans, and I am happy to announce that they made this mission possible," Kibombo said.
He noted that the operation follows previous evacuation missions undertaken by Uganda during conflicts in Sudan and South Sudan in 2023.
Uganda's Ambassador to South Africa, Paul Amoru, said many Ugandans had lost businesses, homes and personal belongings during the attacks.
"Many Ugandans have returned with nothing. Their properties were destroyed, while others were not allowed to carry any of their belongings," Amoru said.
One of the returnees, Namugenyi Aisha, appealed for government assistance to help those returning rebuild their lives.
"All our properties were seized by South Africans, and we were left with nothing," she said.
She urged government to establish livelihood support programmes to enable the evacuees to restart their lives in Uganda.
The violence in South Africa has triggered one of the largest regional repatriation efforts in recent years.
Authorities say more than 900 people have been arrested during anti-migrant protests that swept several provinces after activist groups organised nationwide demonstrations demanding the removal of undocumented migrants.
While many marches remained peaceful, others descended into looting, assaults and attacks on businesses owned by foreign nationals. Police have also confirmed several deaths linked to the unrest.
The unrest has renewed concerns over recurring waves of xenophobic violence that have periodically erupted in South Africa for nearly two decades, with migrants from across Africa frequently blamed for unemployment, crime and pressure on public services despite studies showing they make up only about four percent of the country's population.
Uganda is not the only country evacuating its citizens.
Nigeria has announced that it will seek compensation from South Africa for businesses, vehicles and other property abandoned by Nigerians fleeing the violence. Nigerian officials say they are compiling an inventory of losses with a view to presenting compensation claims to the South African government.
Ghana has also evacuated hundreds of its nationals after one of its citizens was killed during the unrest.
The killing has sparked a diplomatic dispute, with Ghana demanding a full investigation, stronger protection for its citizens and justice for the victim, while South African authorities have disputed Ghana's account of the circumstances surrounding the death, insisting police investigations point to a criminal motive unrelated to the anti-migrant protests.
For Uganda, additional evacuation flights are expected to arrive in Entebbe on Friday as government races to bring home more citizens seeking to escape the worsening security situation in South Africa.