The top U.N. envoy in Somalia said Wednesday that the sudden departure of al-Shabab Islamist fighters from the capital will speed delivery of desperately-needed humanitarian aid if the government acts quickly to secure the city.

Augustine Mahiga told the U.N. Security Council in a videoconference briefing from Mogadishu that al-Shabab's rapid withdrawal from the city presents the first opportunity in years for the transitional government to take complete control of the capital.

"This is a welcome development which, if managed effectively, will expedite political gains as well as the delivery of much needed humanitarian assistance to the thousands of (Somalis) who have travelled to Mogadishu in a desperate attempt to escape the devastating famine," he said.

However, if the weak central government doesn't act quickly, Mahiga warned that warlords are likely to fill the vacuum created by the departure of al-Shabab fighters.

The United Nations estimates that tens of thousands of people have died from malnutrition in Somalia in recent months, and over 11 million people across East Africa need food aid because of a long-running drought.

Catherine Bragg, the U.N.'s deputy emergency relief co-ordinator, told the council that 3.7 million Somalis are "in crisis" including 3.2 million in need of "immediate lifesaving assistance."

According to the U.N.'s Food Security and Nutrition Analysis Unit, "the current situation represents the most severe humanitarian crisis in the world today and Africa's worst food security crisis since Somalia's 1991-92 famine," she said.

"We have not yet seen the peak of the crisis," Bragg warned, citing high levels of severe malnutrition and deaths of children under age 5, combined with increasing cereal prices and a dry harvest season.

Bragg noted that the ability of Somali authorities to ensure delivery of aid and provide security "remains weak," citing the deaths of 10 people last Friday when clan militias attempted to loot food destined for famine victims in an area under control of the government and African Union troops.

Somalia has not had an effective government since 1991 when warlords overthrew a longtime dictator and then turned on each other, plunging the country into chaos. A transitional government, established in 2004 and backed by about 9,000 African Union troops, has been fighting against al-Shabab insurgents.

The Security Council has authorized a 12,000-strong AU force and Mahiga called for stepped up efforts to get the additional 3,000 troops on the ground quickly.

Al-Shabab controlled about a third of Mogadishu until Saturday morning when its fighters abandoned all their bases in the capital. They still hold most of southern Somalia, where tens of thousands are estimated to have starved and tens of thousands more are trying to reach the capital in hopes of finding food.

"Although al-Shabab has described the retreat as only a tactical manoeuvr, the truth remains that al-Shabab has been compelled to retreat from Mogadishu," Mahiga said, crediting African Union and Somali government forces for "pushing back the insurgents."

He warned that the transitional government and the AU force have only limited resources to exploit the opportunity presented by al-Shabab's pullout, and he urged immediate international support.

"Pockets of al-Shabab remain in Mogadishu, the security situation remains precarious and the insurgents are likely to resort to terrorist attacks and guerrilla tactics" targeting the transitional government, AU forces, famine victims and other civilians, he said.

Maj. Gen. Fred Mugisha, the AU commander, also speaking from Mogadishu, told a news conference later that his troops control 95 per cent of the capital.

Mugisha said he needs up to 15,000 troops to handle the expanded peacekeeping duties in Mogadishu and help famine victims. He said the additional 3,000 authorized troops are ready to deploy but need equipment.

Mugisha appealed to the international community to supply the soldiers and assist the AU force with much-needed helicopters, fixed-wing aircraft and other transport.

Both Mahiga and Mugisha said they did not believe al-Shabab made a tactical retreat, though the AU commander said the militants might try to return.

Mahiga urged the weak -- and often feuding -- transitional government "to remain united," institute measures to administer the capital, promote law and order and bring militias under government authority.

"Without immediate action to fill this gap, a real danger exists that the warlords and their militia groups will move forward to fill the vacuum created by al-Shabab's departure," he warned.