Somalia's security forces on Saturday ended the overnight attack by the militant group in the southern port city of Kismayu, a police officer said.
The attack is the latest in a long line of bombing and assaults claimed by Al-Qaeda-linked group Al-Shabaab across Somalia.
A local politician, three Kenyans, three Tanzanians, two Americans and and one Briton were also killed, authorities say.
Four of the attackers were also killed.
"I saw several dead bodies being carried from the scene and people fleeing from the nearby buildings", one man told reporters.
Forty-three-year-old Canadian journalist Hodan Nalayeh and her husband Faird Jama Suleiman were among those who did not survive these attacks.
Hodan Nalayeh, a Somali-Canadian journalist who built a career telling uplifting stories of the Somali community, has died in a hotel attack in Somalia, according to local media.
Omar Suleiman, a US-based imam who knew journalist Ms Nalayeh, paid tribute to her on social media.
Wajir Women Representative Fatuma Gedi also condemned the journalist's killing and eulogised her as a role model to many Somali girls.
The dead included a presidential candidate for August's Jubbaland regional elections, Jubbaland state president Ahmed Mohamed Madobe said.
Another witness Hussein Muktar said: "The blast was very big".
Britain's foreign ministry said it was in touch with local authorities for information about the Kismayo attack.
"She was like, 'I will take this platform and I will use it to shed a light both to Somalians in Somalia and Somalians outside", Shaie said, adding "I'm heartbroken" at her death.
Nur said Nalayeh's death is a tragedy, not only for the Somali community, but for Canada as a whole.
Kismayo is the commercial capital of Jubbaland, a region of southern Somalia still partly controlled by al Shabaab.
"She was an awesome person with an incredible heart", said Mohamed Gialo, a close friend of Nalayeh, who said she helped find his daughter employment after his daughter graduated university.