An explosion hit Imam Zaman Mosque in Kabul on the day of Muslim Friday prayers, followed by gunfire, the Afghan Interior Ministry and police said. At least 13 people were killed and dozens injured in the assault, authorities say.

The assailants stormed the mosque at around 1:15pm local time, local Tolo News reported. A Special Forces unit entered the building following the attack, Najib Danish, spokesman for the interior ministry, confirmed.

"At first a suicide bomber opened fire and martyred two security guards at the entrance of the mosque and then they entered inside," an eyewitness told Reuters.

The attackers who broke into the mosque were wearing police uniforms, another witness told TOLO News.

Meanwhile, more explosions were heard in the area, AP and local media reported.

Islamic State (IS, formerly ISIS, ISIL) has claimed responsibility for the carnage through Amag news agency, which is affiliated with the terrorist group. Local officials have not, however, confirmed that IS is indeed behind the assault.

The attack came as Muslims were preparing to attend Friday prayers.

It also came just three days after a rocket attack struck the Afghan capital on Monday, with one of the projectiles hitting the quarter of the presidential palace and foreign embassies.

The assault did not result in casualties. Prior to the assault, US President Donald Trump announced a more aggressive strategy to defeat the Taliban.