An al-Shabaab chieftain was among the killed, according to Somalia's Chief of Defence Force Brigadier general Odowaa Yusuf Rageh.
Somali security forces have intensified operations against al-Shabaab terrorists in Mogadishu.
Somalia has been struggling with insecurity for years, with al-Shabaab being one of the main threats.
Since at least 2007, al-Shabaab has waged a deadly campaign against the Somali government and international forces, claiming thousands of lives.
The UN has also warned of growing instability in the country, with its periodic reports on Somalia this year detailing attacks by al-Shabaab and pro-ISIL groups.
There were at least 1,518 civilian casualties – 651 killed and 867 injured – in terrorist attacks in Somalia in 2018, followed by 1,459 – 591 killed and 868 injured – in 2019, according to UN estimates.
MP/5651463