One of the last remaining relief agencies in Somalia is shutting down its biggest clinics in Mogadishu because of the rising risk of violence, joining a steady exodus of foreign relief workers from the war-torn country as it struggles with a devastating famine.

Médecins Sans Frontières (Doctors Without Borders) announced today that it has closed two 120-bed clinics in Mogadishu, the biggest of its 13 projects in Somalia. The two clinics have helped to save the lives of nearly 12,000 malnourished children since August, while providing measles treatment or vaccinations for another 68,000.

Two staff members at the MSF clinics, a Belgian coordinator and an Indonesian doctor, were shot dead by a former employee last month. Two other MSF aid workers, both Spanish, were abducted at a Somali refugee camp in Kenya near the Somali border in October.

Story continues below advertisement

"It is hard to close health services in a location where the presence of our medical teams is genuinely life-saving every day," said MSF's general director, Christopher Stokes, in a statement today.

"But the brutal assassination of our colleagues … makes it impossible for us to continue working in this district of Mogadishu."

Many of the biggest foreign relief agencies have been forced to leave Somalia in the past few weeks, even in the midst of the world's worst famine.

The famine has eased in recent months, partly because of a massive $1.3-billion aid campaign and partly because of the beginning of the rainy season. But Somalia still has the highest malnutrition rate in the world, and tens of thousands of people will have died of starvation by time the famine is over, United Nations experts say.

Story continues below advertisement

One of the biggest relief agencies, the International Committee of the Red Cross, disclosed last week that its Somalia relief effort has been blocked by Islamist militants for the past month. The suspension has halted the distribution of food to 1.1 million people, with 140 trucks of food unable to move.

Fighting between the Islamist radicals and an invading force of Kenyan troops has further hampered the distribution of food aid in southern Somalia.

The Islamist militants – known as al-Shabab – control most of southern and central Somalia. In mid-December, they ordered 16 relief agencies to leave the territory that the militants control. Among the evicted groups were some of the biggest in Somalia, including the UN Children's Fund, the World Health Organization, the UN refugee agency, and a long list of European relief organizations.