U.S. Central Command (CENTCOM) chief Gen. Joseph Votel on Thursday urged Pakistan to act against militant groups in the country and across its borders.
He made the demand during a two-day visit to the capital Islamabad where he met Pakistan's top military leadership.
"Gen. Votel acknowledged the progress Pakistan has made, but stressed the [Trump] Administration's message that Pakistan must prevent all militants from operating within and across its borders," said a statement from the U.S. embassy in Islamabad.
During the visit, he met Gen. Zubair Hayat, chairman of the joint chiefs of staff committee, Gen. Qamar Javed Bajwa, Pakistan's army chief, Lt. Gen. Naveed Mukhtar, head of the military's spy agency Inter-Services Intelligence and other officials.
He discussed the importance of improved Afghan-Pakistani relations, and emphasized the need to strengthen border security, the statement added.
In a separate statement, Inter Services Public Relations, media wing of the Pakistan army, quoted Gen. Bajwa as saying: "Peace in Afghanistan is more important for Pakistan than any other country.
Pakistan has done its best despite constraints and shall continue efforts for the sake of its future."
"However, the same was not being reciprocated as evident from the continued attacks from across the border," Bajwa said, referring to recent militant attacks on Pakistan army check posts on the Afghan border, for which Islamabad accuses Afghanistan-based Pakistani Taliban.
Washington has long been accusing Islamabad of providing safe havens to Haqqani network -- a militant group blamed for numerous attacks on the U.S. and Afghan forces in neighboring Afghanistan, including its capital Kabul in recent years.
Pakistan, however, denies the charge, and accuses Kabul of allowing militants to use its soil for attacking Pakistani security forces and civilians.
Islamabad had already agreed to initiate fresh efforts to bring Taliban back to negotiations following an ice-breaking visit of Pakistan's army chief to Kabul earlier this month, according to Pakistani media reports.
Pakistan brokered a landmark round of direct talks between the fragile Afghan government, and the Taliban in Islamabad in July 2015, but the process broke down after the Taliban announced the death of their long-term leader, Mullah Omer, triggering a bitter power struggle within the militant group.
Chances for resumption of the stalled process went further dim following death of Mullah Omer's successor, Mullah Mansur in a U.S. drone strike last year in southwestern Pakistan near the Afghan border.
Several attempts aimed at resuming the halted process have been made since July 2015 by a four-nation group comprising of Pakistan, Afghanistan, US and China -- but they have all failed one after another.