Civilians were killed as Afghan security forces launched an operation against the Taliban in the eastern Khost province, officials said on Sunday.
According to the provincial administration, the action was conducted by Afghan forces in the Sabari district after the Taliban infiltrated the area and closed the route that connects Maidan Wardak province with Khost.
The Interior Ministry said two civilians were killed but the Taliban charged the security forces of killing at least 20, including women and children.
Taliban spokesperson Zabihullah Mujahid said the Afghan government, backed by "foreign occupation forces" has been carrying out operations in various areas of the district.
"Information gathered from the area so far suggests that 20 innocent civilians, mostly women and children have been murdered in their homes... numerous others are wounded, tens of homes, shops and stalls have been destroyed, and all valuables stolen from locals," he said in a statement.
"The Islamic Emirate [Taliban] condemns this horror of the enemy and the killing of civilians in the strongest terms, and considers it an example of the oppression and crime of the Kabul administration and promises to take revenge on the oppressed people from the criminals."
The Interior Ministry, meanwhile, blamed the Taliban for blowing landmines inside the homes of locals during a clean-up operation.
Syed Hamid Roshan, a ministry spokesman, said the Taliban forced the locals to hide the bomb that caused the deaths of a child and a woman.
"Anti-government groups have always used homes, religious schools and mosques as weapon depots, bomb-making factories and shelters for their own purposes, which causes civilian casualties and then the Afghan security forces are blamed," he said.
Violence in Afghanistan has not abated despite the launch of intra-Afghan peace talks last September, which aim to end the 19-year-long conflict in the war-torn country.