The victims were three policemen and two civilians, according to the regional hospital in Herat, in the far west of the country. Herat provincial spokesman Jelany Farhad confirmed that one of the civilians killed was a child.
Four other people were wounded in the attack and brought to the hospital.
There was no immediate claim of responsibility.
The Herat police chief said security forces killed one of the attackers and were searching for two others. Afghan security forces seized an explosives-laden vehicle that they said the attackers brought to the scene.
In December, at least 47 people were killed and 25 wounded during a a seven-hour assault that began with a car bomb at a government building in the Afghan capital of Kabul, authorities said.
A police officer and four attackers were among the dead after the standoff at the National Authority for Disabled People and Martyrs’ Families in Kabul, according to Najib Danish, an Interior Ministry spokesman.
The official said planning is underway, and it could take months to withdraw the nearly 7,000 troops.