The Taliban have been blamed for attacks on checkpoints across Afghanistan that have killed 29 members of the security forces.
Nineteen security personnel were killed in a battle in the northern district of Khwaja Ghor, a spokesman for the Takhar provincial governor said.
The Taliban fled the scene after reinforcements arrived, the spokesman added.
Seven were killed in northern Balkh province, according to a spokesman for the provincial police chief.
The spokesman also said a child was caught in the crossfire and wounded. He added that five Taliban were killed during the attack.
In the western Badghis province, the Taliban struck an army checkpoint, killing three soldiers and wounding 10, according to a local police spokesman.
The Taliban have not claimed responsibility for the attacks.
The release of up to 5,000 Taliban prisoners and 1,000 government officials held captive by the insurgents ahead of intra-Afghan negotiations is a condition of the US-Taliban deal.
Earlier in the month, the Taliban confirmed they would be releasing 20 Afghan government prisoners as part of the first phase of its commitment under the peace deal.
The Taliban have not been attacking US and NATO troops since the agreement was signed.
However, they have struck Afghan forces in outlying areas.
Cover image: Library picture of a Taliban training camp (Picture: PA).