The Taliban claimed responsibility for the attacks, among the most deadly in the province in many months
Taliban insurgents have stormed security posts in west Afghanistan, killing 21 police and pro-government militia members, officials said on Monday, the latest in a surge of attacks that has cast doubt on tentative steps towards talks.
The Taliban attacked the checkpoints in two different parts of Badghis province, which is on the border with Turkmenistan, late on Sunday, provincial officials said.
Abdul Aziz Bek, head of the Badghis provincial council, said 14 policemen and seven members of pro-government militias were killed, while nine were injured.
A second government official, Jamshid Shahabi, a spokesman for the Badghis provincial governor, said more than 15 Taliban militants were killed and 10 wounded in the clashes.
The Taliban claimed responsibility for the attacks, among the most deadly in the province in many months.
Qari Yousuf Ahmadi, a Taliban spokesman, said in statement they killed 34 members of the security forces and pro-government militias and seized many weapons and ammunition.
Leaders of the hardline Islamist group and the US officials are scheduled to meet this month to discuss the withdrawal of foreign forces and a possible ceasefire.
Officials from the warring sides have met at least three times in recent months to try to agree on a way to end the 17-year war. But in the meantime, both sides are keeping up their attacks.
The Taliban say they are fighting to topple the Western-backed government and restore strict Islamic law after their ouster in 2001.
The United States and its allies say they want to stop Afghanistan from becoming a haven for international Islamist militants plotting attacks in the West.
In a separate incident on Monday, at least five civilians were killed and eight wounded in a bomb blast in the eastern province of Paktika.
The Taliban left the bomb in a village square, said provincial official Mohammad Rasoul Adel. A Taliban spokesman was not immediately available for comment.