Militants linked to the Islamic State group killed around 30 civilians, including children, in the central Afghan province of Ghor, the local government said Wednesday.
The incident occurred late Tuesday north of the provincial capital Firoz Koh, with the government calling it a revenge attack after a local IS commander was killed.
"Our security forces with the help of locals conducted an operation and killed a Daesh (IS) commander yesterday. Daesh fighters in return abducted around 30 villagers, mostly shepherds," Ghor Governor Nasir Khazeh told AFP.
"Their dead bodies were found by local people this morning."
There has so far been no official claim of responsibility from the group.
The killings underscore unravelling security in Afghanistan as the resurgent Taliban continue a push into urban centres 15 years after they were toppled from power by the US invasion.
IS fighters are also making steady inroads into Afghanistan, winning over sympathisers, recruiting followers and challenging the Taliban on their own turf, primarily in the country's east.
In March Afghan President Ashraf Ghani announced that the Islamists had been defeated after local security forces claimed victory in a months-long operation against the group.
But IS militant have continued to launch deadly strikes in the country.
In July, IS jihadists claimed responsibility for twin explosions that ripped through crowds of Shiite Hazaras in Kabul, killing at least 80 people in the deadliest single attack in the Afghan capital since 2001.