Ethiopian and Somali troops have taken a strategic stronghold of Islamist militants in south-western Somalia.
Eyewitnesses told the BBC that about 50 vehicles, including some 20 tanks, had entered Baidoa, which was not defended.
After the southern port of Kismayo, the town was the most important al-Shabab base.
The news comes as the UN Security Council voted to increase the African Union force in Somalia from 12,000 to 17,731.
These developments come ahead of a major conference to be hosted by the UK on Thursday aimed at ending two decades of conflict in the troubled country.
Al-Shabab, which has recently joined al-Qaeda, confirmed that it had withdrawn its forces from Baidoa as part of a "tactical retreat" and threatened to start a guerrilla war in response.
"The takeover does not mean that the enemy will enjoy the city, there will be more bloodshed," said Sheikh Mohamed Ibrahim, an al-Shabab commander, according to the AFP news agency.
A Somali government military commander in the town said his forces were moving to the outer edges of the town to ensure they had full control of it.
"We have taken control of Baidoa without a single shot, it is a great day for the people who are now welcoming us warmly," Muhidin Ali said, according to AFP.
The UN Security Council unanimously agreed to bolster the number of African Union forces in Somalia by more than 5,500 to 17,731 - this would include the Kenyan troops that entered the country last October in pursuit of al-Shabab militants.
The resolution passed by the 15-nation council also gave the African force a stronger mandate to attack al-Shabab militants and substantially increase international funding for the military operation.
The London conference is expected to be attended by senior representatives from more than 50 governments and international organisations.
Somalia's Western-backed transitional government, officials from the northern breakaway republic of Somaliland, US Secretary of State Hillary Rodham Clinton and UN Secretary-General Ban Ki-moon are among those due to be present at the one-day summit.
Speaking in London on Wednesday, British Prime Minister David Cameron said the summit aimed to "work... with all the parts of Somalia - which has been more blighted by famine, by disease, by violence, by terrorism than almost any other in the world - to give that country a second chance".
Witnesses say that after fierce fighting on Tuesday, al-Shabab fighters pulled out of Baidoa, allowing Somali and Ethiopian forces to seize the town on Wednesday without a battle.
BBC Somali service analyst Abdullahi Sheikh says Baidoa is a big loss to al-Shabab, as the main road linking Mogadishu to the south-west and parts of Kenya and Ethiopia passes through the city.
It is also the business route for most commodities that are transported from Mogadishu to other towns in the region.
Baidoa also has an airport, which the Islamist group is thought to have used to bring in weapons.
As the Ethiopians advanced, many residents fled the town on donkeys and vehicles.
Al-Shabab still controls many southern and central areas of the country but is also under pressure from Kenyan forces in the south.
Last year, AU troops in support of the UN-backed government pushed al-Shabab out of the capital.
However, the militants continue to stage suicide attacks in the city.