The Taliban said Wednesday they would fight only to defend themselves over the Muslim holiday of Eid al-Adha, but stopped short of declaring a formal ceasefire.

The militants are waging sweeping offensives across Afghanistan, snapping up territory, seizing border crossings and encircling cities, with the withdrawal of foreign troops all but complete.

"I can confirm we are in defence status during Eid," a spokesman for the Taliban told AFP, without offering further details.

Eid al-Adha is one of the biggest festivals on the Muslim calendar, and sees livestock sacrificed to share with the less privileged. In Afghanistan, celebrations started this Monday and will run to the end of Friday.

For past Islamic holidays, the militants have declared a pause in fighting with government forces, offering a brief respite to Afghans who can visit family in relative safety.

But the group has been criticised for using ceasefires to reinforce their positions and resupply fighters, allowing them to attack Afghan security forces once the truce expires.

Afghan security personnel stand guard outside the blue mosque during the Eid al-Adha prayers in Herat
Afghan security personnel stand guard outside the blue mosque during the Eid al-Adha prayers in Herat AFP / Hoshang Hashimi

The Taliban comment comes a day after President Ashraf Ghani said in a speech that the Taliban had proved "they have no will and intention for peace," with negotiations between the two warring sides achieving little.

Minutes before his address, at least three rockets landed near the presidential palace where Ghani held outdoor prayers with top officials to mark the start of Eid.

The attack was claimed by the Islamic State (IS) group.

While ideologically different, the much smaller IS has been accused in the past of acting as a proxy for the Taliban -- particularly in attacks targeting civilian government workers.

More than a dozen diplomatic missions in Kabul this week called for "an urgent end" to the Taliban's current offensive, saying it was at odds with claims they want to secure a political deal to end the conflict.

That statement followed another round of inconclusive talks in Doha over the weekend between the two sides, that many had hoped would kickstart the ailing peace process.

Over the weekend, the Taliban's supreme leader Hibatullah Akhundzada said he "strenuously favours" a political settlement -- even as the hardline Islamist movement capitalises on the last stages of the pull-out of US-led foreign troops.