A least four people were killed when a suicide bomber as young as 12 struck Kabul's heavily fortified diplomatic quarter on Tuesday.
It was the first attack targeting the Afghan capital's "Green Zone" since a massive lorry bomb ripped through the area on May 31, killing or wounding hundreds, and prompting authorities to strengthen protection.
ISIL claimed responsibility for Tuesday's attack, which follows a spate of suicide assaults by the group and Taliban militants on security installations and mosques in recent weeks.
A western security source said the attacker appeared to have been targeting workers leaving an Afghan defence ministry facility inside the heavily protected zone.
"The suicide attack was carried out by an underage bomber, a boy we think 13 or 15 years old, killing at least four and wounding over a dozen more civilians," said interior ministry spokesman Najib Danish.
He added that the casualty toll could change.
A police spokesman said the attacker may have been as young as 12.
Defence ministry spokesman Dawlat Waziri said the attacker "made it through the first checkpoint but was stopped at the second checkpoint and detonated".
"We don't know the target but it happened a few metres from the defence ministry's foreign relations office. There were no casualties to our personnel," Mr Waziri said.
"I was 100 metres away when the explosion happened and as I ran towards the site I saw several people lying in blood - one had been hit in the head and was moving. It was a horrible scene," an eyewitness told the Afghan television channel TOLOnews.
Another witness said: "A lot of people were dead and injured and there was no one to carry them away."
The attack struck the heart of the city's diplomatic area, where many embassies and the head offices of major international organisations, including Nato's Resolute Support mission, are located.
The last major assault in Kabul was on October 21 when a suicide attacker hit a busload of Afghan army trainees, killing 15.
A day before that, a suicide bomber pretending to be a worshipper blew himself up inside a Shiite mosque during evening prayers, killing 56 and wounding 55.
On Friday and Saturday last week, meanwhile, Taliban insurgents, some wearing night-vision goggles, killed 22 Afghan policemen in separate attacks on checkpoints.
Security in Kabul has been ramped up since the May 31 lorry bomb that went off on the edge of the Green Zone near the German embassy, killing 150 people and wounding 400 others.
Special truck scanners, barriers and permanent and mobile checkpoints have been rolled out across the city.