Pakistan and Afghanistan's Taliban government have agreed to an 'immediate ceasefire' after more than a week of deadly fighting.

The foreign ministry of Qatar, which mediated talks alongside Turkey, said both sides had agreed to establish 'mechanisms to consolidate lasting peace and stability'.

Zabihullah Mujahid, a spokesman for the Taliban, said ending 'hostile actions' was 'important', while Pakistan's foreign minister called the agreement the 'first step in the right direction'.

Both sides claim to have inflicted heavy casualties during the clashes, the worst fighting since the Taliban returned to power in 2021.

Islamabad has long accused the Taliban of harbouring armed groups that carry out attacks in Pakistan, which it denies.

Clashes intensified along the 1,600-mile (2,574 km) mountainous border after the Taliban accused Pakistan of conducting attacks on the Afghan capital, Kabul.

Rumours circulated that blasts in Kabul were a targeted attack on Noor Wali Mehsud, the leader of Pakistan's Taliban. In response, the group released an unverified voice note stating Mehsud was still alive.

In the ensuing days, Afghan troops fired on Pakistani border posts, prompting Pakistan to retaliate with mortar fire and drone strikes.

At least 17 Afghan civilians have reportedly been killed and hundreds more injured according to the UN Assistance Mission in Afghanistan.

A temporary truce was declared on Wednesday; however, cross-border strikes persisted.

On Friday, the Taliban claimed Pakistan had conducted an airstrike resulting in the deaths of eight, including three local cricket players.

The new agreement stipulates that the Taliban will not support groups conducting attacks against the Pakistan government, while both parties vowed to avoid targeting each other's security forces, civilians, or critical infrastructure.

Pakistan's Defense Minister Khawaja Asif remarked that the ceasefire indicates 'terrorism from Afghanistan on Pakistan's soil will be stopped immediately', with plans for further discussions in Istanbul next week.

Once a significant supporter of the Taliban after their ouster in 2001, relations have soured as Islamabad accuses the group of offering refuge to the Pakistan Taliban, which has waged an insurgent war against government forces, claiming at least 600 attacks on Pakistani forces over the past year.