Afghan President Ashraf Ghani says the Islamic State of Iraq and the Levant (ISIL) group has been defeated in eastern Afghanistan, where it had taken over some remote districts.
Afghan forces had dislodged ISIL loyalists from regions of Nangarhar province bordering Pakistan, said Ghani on Sunday, speaking at the opening of parliament.
He also said Afghanistan will be a "graveyard" for ISIL.
Afghan forces have claimed victory following a 21-day operation in the Achin and Shinwar districts of Nangarhar, claiming to have killed at least 200 ISIL affiliates.
ISIL has had a presence in Afghanistan for more than a year. Officials have said most fighters calling themselves ISIL are disaffected Taliban members.
According to US Army General John Campbell, who leads the international forces in Afghanistan, there were between 1,000 and 3,000 ISIL fighters in the country.
READ MORE: ISIL hits Afghan airwaves to drum up support
The armed group recently launched a radio station with a one-hour-long Voice of Caliphate broadcast in Pashto language in Nangarhar's Achin district.
Last year, ISIL beheaded a group of ethnic Hazara people - four men, two women and a child - with razor wire after abducting them in Ghazni city. Their bodies were later found in Arghandab district of Zabul province.
The violence prompted mass protests in the country. Thousands of demonstrators took to the streets in the capital, Kabul, urging the government to take action against rising violence against Afghan civilians.