The Taliban have taken control of a district near the Afghan capital, Kabul, a day before a three-day ceasefire is due to begin.
The militants confirmed on Tuesday that they had captured Nerkh district in Wardak province in a "surprise attack".
Nerkh is the second district in a week to fall to the Taliban.
Afghanistan is seeing increasing violence as the US and Nato prepare to pull out remaining troops by 11 September.
"The district centre of Nerkh in Maidan Wardak province, the police headquarters, the intelligence department and a large army base there were all captured," Taliban spokesman Zabihullah Mujahid said on Twitter.
He added that "many enemy soldiers" had been killed or wounded.