The Taliban said it has agreed to a nationwide temporary ceasefire in Afghanistan, opening to the door for a possible peace agreement with the US.

Any peace deal could allow Washington to bring home its troops from Afghanistan and end its 18-year military involvement in the country.

Currently there are an estimated 12,000 US troops in Afghanistan.

If any deal is to be agreed, the US wants a promise that the Taliban would not allow Afghanistan to be used as a base by terrorist groups.

The US has around 12,000 troops in Afghanistan. Credit: AP

The Taliban chief must approve the agreement but that is expected.

No official announcement about the duration of the ceasefire has been announced but it is thought to be around 10 days.

Members of a Taliban negotiating team met for a week with the group’s ruling council before they agreed on the brief ceasefire.

Members of a peace movement in Kabul Credit: Rahmat Gul/AP

The negotiating team returned on Sunday to Qatar where they maintain their political office.

A key pillar of the agreement, which the US and Taliban have been hammering out for more than a year, is direct negotiations between Afghans on both sides of the conflict.

Those talks are expected to be held within two weeks of the signing of a US-Taliban peace deal.

President Donald Trump surprised troops in Afghanistan at the end of November. Credit: AP

They will probably decide what a post-war Afghanistan will look like, and what role the Taliban will play.

The negotiations would cover a wide range of subjects, such as the rights of women, free speech and the fate of tens of thousands of Taliban fighters, as well as the heavily armed militias belonging to Afghanistan’s warlords who have amassed wealth and power since the Taliban’s ousting from power.

The temporary ceasefire had been proposed by US envoy Zalmay Khalilzad during the last round of talks.

Trump had visited troops in Afghanistan in November and declared talks had been ongoing to try and negotiate a peace deal with the Taliban.