A suicide bombing at an education centre in Afghanistan's capital Kabul killed 24 people including teenage students and wounded dozens more on Saturday, officials said.
A Ministry of Interior spokesman, Tariq Arian, said security guards had identified a bomber who detonated explosives in the street outside the Kawsar-e Danish centre.
Most of the victims were students aged between 15 and 26, according to the health ministry. Fifty-seven were injured in the attack, the interior ministry said.
A Taliban spokesman on Twitter denied responsibility for the attack, which came at a sensitive time as teams representing the insurgents and the government meet in Qatar to seek a peace deal.
Islamic State claimed responsibility in a statement on Telegram, without providing evidence.
Family members gathered at a nearby hospital, searching for missing loved ones among bags containing the remains of those killed, laid out on the hospital floor, while outside orderlies wheeled injured patients on stretchers for treatment, a Reuters witness said.
The attack, which was condemned by NATO and the Afghan government, took place in an area of west Kabul that is home to many from the country's Shia community, a religious minority in Afghanistan targeted in the past by groups such as Islamic State.
Dozens of students died in the same area of Kabul in an attack on another education centre in 2018.
A teacher at the Kawsar-e Danish centre, who asked not to be named due to security concerns, said he and other teaching staff were in shock at the targeting of the institution which had provided tutoring to give thousands of children a pathway to higher education.
"All the students were full of energy, belonging to poor families but hoping for a brighter future," he said.
The latest attack came on the back of heavy fighting in multiple provinces in recent weeks, which has displaced thousands of civilians.
The US Special Envoy for Afghanistan Zalmay Khalilzad early on Sunday on Twitter called again for an immediate reduction in violence and an acceleration in the peace process, citing rising violence in the country in recent weeks including a finding by the human rights commission that an Afghan government airstrike had killed 12 children.
"How much more can we endure, as individuals and as society? How many times can we rise?" asked Shaharzad Akbar, chair of Afghanistan's Independent Human Rights Commission on Twitter shortly after Saturday's attack, saying the targeting of civilians was a war crime.