The Taliban fighters attacked a military outpost on the Baghlan-Samangan highway in Pul-e-Khumri, capital of the province.
According to local officials, two other Afghani soldiers are missing, and two army vehicles were destroyed in the attack.
Military officials claimed that the Taliban had also suffered heavy casualties.
The Taliban has not commented on the attack yet.