Britain has removed its military attache from his post in Pakistan after he lost the confidence of the British High Commission, officials said.
The High Commission lost confidence, London said
The Ministry of Defence said Brig Andrew Durcan had been removed after "an internal investigation".
Britain's Sun newspaper had alleged Mr Durcan had formed an "inappropriate relationship" with a suspected female Pakistani spy.
The countries have worked closely in anti-terror operations in recent years.
The Ministry of Defence refused to confirm the claims in the Sun, only saying: "The ministry decided to replace him after he lost the confidence of the High Commission."
The Sun said Mr Durcan, 56, had been "tricked into a close friendship by the attractive woman".
It said there was no evidence classified information or British agents had been compromised.
The paper described the woman as a "defence academic" who was "also believed to be an undercover agent for rogue elements within Pakistan's intelligence services".