The incident happened in Sadokhel area of Khyber tribal region where Taliban and Lashkar-e-Islam militant groups are active.
“An improvised explosive device planted along the roadside went off as two vehicles of paramilitary Frontier Corps (FC) passed by, killing two soldiers and wounding six others,” senior local administration official Muhammad Tayyab Ali told AFP.
He said the blast destroyed one of the vehicles.
A local intelligence official also confirmed the incident and casualties.
Nobody has so far claimed responsibility for the incident but it occurred just two days after the Pakistani Taliban announced a month-long ceasefire aimed at resuming peace talks with the government.
Dialogue between Islamabad and the Tehreek-e-Taliban Pakistan (TTP) that began last month was suspended after the militants killed 23 soldiers.
Khyber, one of the seven semi-autonomous tribal regions, straddles the NATO supply line into Afghanistan, used by US-led troops to evacuate military equipment ahead of their withdrawal later this year.
Pakistani troops have been fighting for years against homegrown insurgents in the tribal belt, which Washington considers the main hub of Taliban and Al-Qaeda militants plotting attacks on the West and in Afghanistan.