Police said the blast, which took place in a location where intelligence officers are known to congregate, killed at least 11 people.
Witnesses said the attacker sped towards the tea shop in a car before detonating the explosives.
The al-Qaida-linked group al-Shabab has increased the frequency of attacks in Somalia's capital in recent weeks, raising the spectre of a return to daily violence.
Last week an al-Shabab team attacked the presidential palace with two car bombs and seven gunmen. A car bomb exploded near a UN convoy earlier this month.
After controlling most of Mogadishu for years, al-Shabab was pushed out by African Union forces in August 2011.
However, al-Shabab has increased its pace of attacks in recent weeks, including the use of mortar fire attacks, complex suicide team attacks and even targeted murders.