Guards at Hotel Sahafi and police officers opened fire after suicide attackers detonated two bombs in a car close to the hotel and the offices of the Criminal Investigation Department in Mogadishu, news agency Reuters quotes police as saying.

A third blast then went off in the busy street 20 minutes later.

A police officer told Reuters that 17 people had been killed in the blast but the news agency says its photographer has counted 20 bodies.

No group has claimed responsibility, but militant group al-Shabab has been behind previous attacks in the capital.