A high-rise where the gunmen had sought refuge in Kabul's diplomatic district has reportedly been cleared. Al Jazeera said that Nato helicopters circled the building overnight Tuesday to flush them out.
The attackers had used the building as a base from which to fire rockets and the embassy and Nato complex.
Siddiq Siddiqi, an interior ministry spokesman, told Agence France-Presse:
The last attackers are dead and the fighting all over. There were six terrorists in the building and all are dead.
Police and hospital sources said at least three policemen, four civilians and nine Taliban fighters were killed and several others injured in the attack and ongoing gun battle.
Other reports from the BBC say 11 civilians were killed, including three children.
(Read more on GlobalPost: Kabul attack: shape of things to come?)
No U.S. Embassy staff were among the casualties, but Nato said six International Security Assistance Force personnel were injured.
The attack comes as U.S. and other foreign forces begin troop withdrawals.