Five rockets have hit a important US airbase in Afghanistan but there were no casualties, the NATO-led force in Afghanistan has said, in an attack claimed by ISIL (ISIS).

The attack comes weeks after the Taliban and the United States reached a deal on the withdrawal of US-led international troops in exchange for Taliban security guarantees.

More:

The Afghan affiliate of ISIL, known as the Islamic State Khorasan (ISIS-K), have not been included in the pact.

"Five rockets were fired at Bagram airfield early this morning," the NATO-led mission, Resolute Support, said on Twitter on Thursday, referring to the main US airbase in Afghanistan, north of Kabul.

"There were no casualties."

ISIS-K said in a statement on social media that their fighters had targeted a helicopter landing pad at Bagram.

A Taliban spokesman said on Twitter that his group was not behind the attack.

ISIS-K first appeared in eastern Afghanistan in 2014, and has since made inroads into other areas, particularly the north.

The US military estimates their strength at 2,000 fighters. Some Afghan officials estimate the number is higher.

ISIS-K fighters, who battle foreign and Afghan government forces as well as the Taliban, have carried out some of the deadliest attacks in Afghanistan's urban centres in recent years.

Last month, ISIS-K gunmen attacked a Sikh religious complex in the capital, killing 25 people.

Prisoners release

The Taliban, as part of their agreement with the US, have promised to open peace talks with the US-backed Afghan government but little progress has been made.

The Afghan government has begun the release of Taliban prisoners from a jail near the Bagram base, a step seen as an attempt to build confidence for the Taliban talks.

A hundred Taliban members were scheduled to be freed on Thursday from detention at a jail near the base, following the release on Wednesday of another 100 Taliban members.

The prisoner exchange deal means the government would free 5,000 Taliban prisoners, and the Taliban would release 1,000 members of the Afghan security forces in exchange.