At least nine people were killed when fighters from the Somali Islamist group al Shabaab set off a car bomb at the gate of a popular park and near a hotel in the capital, sending a plume of smoke above the coastal city.
Police Major Ahmed Abdullahi said he counted at least nine dead, and 30 others were injured. He said three attackers were shot dead by police. "The area is secured," he told Reuters.
Al Shabaab said its fighters were behind the blast and also said its fighters had stormed the hotel.
Initial reports indicated a car bomb struck the gate of the Peace Garden park behind Mogadishu's Somali Youth League hote, known locally as the SYL Hotel. Most people reportedly escaped through another gate. Gunfire erupted after the blast but later died away. Walls at the hotel sustained damage.
"My sister, classmates and I were taking pictures at the peace garden when the car bomb hit the gate of the park. We all rushed through the back gates," witness Halima Nur told Reuters by phone after the attack.
She said scores of people were in the park when the blast took place, saying there was "nearly a stampede" as people rushed out.
Al Shabaab has often launched attacks in Mogadishu on a Friday — the Somali weekend — when more people visit hotels and restaurants. Residents reported gunfire after the blast. The group told Reuters it was responsible for the attack.
"We started with a car bomb and then stormed the hotel. We are inside it and fighting continues," al Shabaab's military operations spokesman, Sheikh Abdiasis Abu Musab, said.
Al Shabaab has carried out an insurgency in Somalia since 2006, with the aim of toppling the secular government in order to implement Islamic law.
The al Qaeda-aligned militants have been driven out of major strongholds in Somalia by the African Union mission in the country in recent years and Somali army offensives, but the group still controls some rural areas and often launches guerrilla-style assaults and bomb attacks.
Al Shabaab gunmen attacked a beach earlier this year, killing more than a dozen people, and in February a suicide bomber linked to the group detonated a bomb on a plane leaving Mogadishu's international airport. The plane was able to safely land with minor damage to the fuselage, but the bomber was sucked out of the plane through the hole created by the explosion.
The militant group killed four people and injured eight others in a mortar attack on Thursday near the presidential palace in the capital Mogadishu. Al Shabaab had reportedly targeted the palace but the mortars went off some distance away, ending up about 300 meters from the nearby house of parliament.
This is a breaking news story, please check back for updates.
Follow VICE News on Twitter: @vicenews