Two suicide bombers detonated explosives-laden cars on Tuesday outside the offices of the UN's mine clearing agency and a Somali army checkpoint in Mogadishu, killing 13 people, including seven guards, Somali police officials said.

The two blasts took place near the African Union base, Somali police chief Gen. Mohamed Sheikh Hassan said at a press conference.

Somalia's Islamic extremist rebels, al-Shabaab, claimed responsibility for the bombings, according to the group's Andalus radio station.

A policeman stands guard near the air-control tower of an airport in Mogadishu following the two bombings. The Islamic extremist rebels, al-Shabab, have claimed responsibility for the attacks. (Ismail Taxta/Reuters)

Unlike previous attacks by al-Shabab, which is linked to al-Qaeda, gunmen did not accompany the suicide bomber, said police Capt. Mohamed Hussein. The first suicide car bomber tried to speed through the barrier at the UN office but guards shot at the car, he said.

The guards at the UN offices were from a private security firm, said a police official, who insisted on anonymity because he isn't authorized to speak to the press.

A second suicide blast targeted a checkpoint manned by Somali security forces near the African Union base in Mogadishu, said Hussein. Casualties there remain unclear.

Al-Shabaab is waging an insurgency against Somalia's weak UN-backed government with the goal of establishing an Islamic emirate in Somalia, ruled by a strict form of Islam.

A United Nations peacekeepers' armoured personnel carrier is seen near the scene of the suicide bombing. (Ismail Taxta/Reuters)

Earlier this month, eight soldiers were killed when an al-Shabaab suicide car bomber targeted a Somalia military training camp and attackers then entered the base on foot.

More than 22,000 troops and police serve in the African Union force, which also includes troops from Burundi, Djibouti, Kenya, Sierra Leone and Ethiopia.

Al-Shabaab opposes the presence of foreign troops in Somalia and has launched attacks in countries that have contributed to the AU force.

Although al-Shabaab was ousted from the Somali capital, Mogadishu, in 2011, it continues to wage a deadly guerrilla campaign that includes suicide bombings.

"Al-Shabab is desperately seeking relevance and will do anything to keep in the news headlines," the AU Special Representative for Somalia, Ambassador Francisco Caetano Madeira, said in a statement.