A prayer ceremony for Mujahid's mother, who died last week, was being held at the mosque on Sunday afternoon, the spokesman had written on social media on Saturday, adding "all people and friends are invited to attend".
Ahmadullah, a shopkeeper nearby, told AFP,"I heard the sound of an explosion near the Eid Gah Mosque followed by guns firing.
"Just ahead of the blast the Taliban had blocked the road to hold a prayer ceremony for Zabihullah Mujahid's mother in the Eid Gah Mosque."
AFP journalists in two locations in the capital also heard the blast and shooting.
Ambulances carrying the wounded were seen rushing towards Kabul's Emergency Hospital in the Shahr-e Naw area.
The hospital said on Twitter that four patients were being treated.
Medical staff waited outside, AFP journalists saw, as people arrived in blood-stained clothes.