The Pakistan Army said on Thursday that a soldier was killed in firing from across the Afghan border.
In a statement, the Inter-Services Public Relations (ISPR) said that terrorists fired on a Pakistani military post from the Afghan side of the border in the Mohmand tribal district, Khyber Pakhtunkhwa, on Wednesday night, Xinhua news agency reported.
Pakistani troops responded promptly and during exchange of fire, but the soldier of the paramilitary Frontier Corps lost his life, the ISPR statement said.
The outlawed Tehrik-e-Taliban Pakistan (TTP) terror group claimed responsibility for the attack.
Pakistani security officials said that militants have crossed the border into Afghanistan as a result of major operations in the country's tribal regions.
Pakistan and Afghanistan share a nearly 2,600-km border, mostly porous.
Mohmand, bordering Afghanistan's Kunar province, is one of Pakistan's seven tribal districts, which was once a Taliban stronghold.