The gunmen attacked the Imam Ali shrine in the vicinity of Karte Sakhi area of the city.
The Ministry of Interior spokesman Sediq Sediqi confirmed the area has been cleared and the last attacker was shot dead.
Sediqi further added that the number of casualties will be released later.
However, a security source confirmed that 14 people were killed and around 36 others were wounded in the attack which was launched around 7:30 pm
Eyewitnesses and local residents in Karte Sakhi area earlier said sporadic clashes continued in the area for several hours as scores of Afghan forces arrived in the area to eliminate the attackers.
According to one of the eyewitnesses, the attack was initially launched by gunmen who started shooting the worshipers and at least one of the gunmen detonated his suicide vest.
They also added that another militant was shot dead by the security forces while one of them continued to resist the security forces before he was shot dead.
No group has so far claimed responsibility behind the incident.