Islamic State has a small but potent presence in Afghanistan, and has claimed several high-profile attacks like the one at a Save the Children office in Jalalabad

A French woman fighting for the Islamic State group in Afghanistan has been detained, Afghan officials said Friday, amid fears that IS militants fleeing Syria and Iraq are finding their way to the country.

The woman was captured during a military operation in the northern province of Jowzjan -- an IS stronghold -- on Thursday night, several officials said.

AFP recently reported that French and Algerian fighters, some arriving from Syria, had joined the group's Afghan franchise in the restive province.

"In a joint operation between NDS and Afghan special forces, five Afghan men and a French woman fighting for IS were arrested in Darzab district of Jowzjan," the National Directorate of Security (NDS), Afghanistan's spy agency, said in a statement.

The Defence Ministry confirmed that a "French insurgent woman was among those detained". Six IS fighters were also killed, it said.

Afghan officials did not clarify how they identified the woman's nationality. One official described her to AFP as "French speaking". They provided no further details about the woman or where she had come from.

Provincial police chief Faqir Mohammad Jawzjani told AFP that US forces were also involved in Thursday's operation.

"Four Daesh fighters were killed and one French woman... was also detained," Jawzjani said, using the Arabic acronym for IS.

He added that two other French IS fighters were killed in the province recently.

Jawzjani said Afghan and US forces took the woman into custody -- which was confirmed by the provincial governor's spokesman Reza Ghafoori.

Ghafoori said two Uzbek fighters had also been detained.

But a US military spokesman for the NATO-led Resolute Support mission in Afghanistan declined to respond and referred AFP to NDS.

- Disrupting IS -

Afghan and US special forces have ramped up airstrikes and ground offensives against IS fighters in Jowzjan in recent months, which the Americans say have "disrupted" the group's capacity to use foreign fighters.

In January, Afghan forces caught the group's "head facilitator of foreign forces". Two months later, his two successors were killed in a US airstrike, a Resolute Support statement on Thursday said.

US and Afghan forces conducted a "nighttime raid" on Thursday in Mughul village in Darzab, the statement added. It made no mention of a French female fighter.

Most of the fighters in Jowzjan were "Pakistani Pashtun", General John Nicholson, commander of US and NATO forces in Afghanistan, said in the statement.

Some were from the Islamic Movement of Uzbekistan and there was "probably 10 percent that's from a variety of sources around the world", he added.

IS has a relatively small but potent presence in Afghanistan, mainly in the eastern province of Nangarhar and more recently Jowzjan. It also has cells in Kabul, and has claimed several high-profile attacks in recent months.

But it is dwarfed by the much larger Taliban, which also has had at least one European in its ranks.

A German national was recently arrested with the Taliban in the southern province of Helmand, Afghan officials said.