Medical aid group Doctors Without Borders confirmed two of its staff members were killed in a shootout at its offices in the Somalia.
The aid group said a 53-year-old Belgian national and a 44-year-old Indonesian were killed during attacks on the group's compound in Mogadishu.
"The exact circumstances of the shooting are not yet clear," the group said in a statement. "Our priority is to take care of those most affected by this tragedy, in particular the families and the colleagues of the victims."
It added that it was relocating "some" staff in Mogadishu for security reasons. It remained committed to carrying out humanitarian work in the city and elsewhere in the country.
One of the workers was killed during the attack and the other died later in a hospital following surgery. Both had been working for the organization for at least a decade.
Doctors Without Borders is one of the few aid organizations operating in Somalia. Al-Qaida's affiliate al-Shabaab, in control of the country's south, banned some humanitarian groups from working in Somalia.
Two workers with Doctors Without Borders were abducted early this year from Kenya. Kenya had sent military forces to southern Somalia in response to a rash of kidnappings of Westerners in the region.