Islamabad has fenced most of the 2,600-kilometre border despite opposition from Kabul, which has always contested the British-era boundary demarcation that splits families and tribes on either side.
Taliban soldiers in Afghanistan have disrupted the erecting of a security fence by the Pakistani military along the border between the two countries.
Afghan defence ministry spokesman Enayatullah Khwarazmi said on Wednesday that Taliban forces stopped the Pakistani military from erecting an "illegal" border fence along the eastern province of Nangarhar on Sunday.
He played down the incident, saying everything was now normal. The Pakistan army did not respond to a request for comment.
Pakistan has fenced most of the 2,600 km (1,615 mile) border despite protestations from Kabul, which has always contested the British-era boundary demarcation that splits families and tribes on either side.
READ MORE: Pakistani Taliban refuses to extend ceasefire with government
A video circulated on social media showed Taliban soldiers had seized spools of barbed wire and one senior official warning Pakistani soldiers stationed in security posts in the distance not to try to fence the border again.
Taliban spokesman Bilal Karimi said they were investigating the incident.
Taliban and Pakistani forces came face-to-face over the border incident, two Taliban officials told Reuters news agency on the condition of anonymity, and the situation was tense.
They added that following the incident there was cross border mortar fire from Pakistani territory further north along the frontier into Afghanistan's Kunar province on Wednesday.
It was unclear if the incidents are linked. The officials said Afghan military helicopters could be seen patrolling the area.
The fencing was a main reason behind the souring of relations between previous US-backed Afghan governments and Islamabad.
The current standoff indicates the matter remains a contentious matter for the Taliban, despite its close ties to Islamabad.
READ MORE: Islamabad in talks with groups of Pakistani Taliban, PM Khan reveals
The lawless mountainous border was historically fluid before Pakistan began erecting a metal fence four years ago, of which it has completed 90 percent.
The border incident happened the day foreign delegates from around the world gathered in Islamabad for a summit of the Organisation of Islamic Cooperation to discuss the unfolding humanitarian disaster in Afghanistan.