The Security Service MI5 kept a secret file on Harold Wilson throughout his years as an MP and prime minister, it was disclosed today.
The official history of the service, serialised in The Times, discloses that the file was opened when he first entered Parliament in 1945, and was maintained throughout his premierships of 1964-70 and 1974-6.
However Professor Christopher Andrew, the author of The Defence of the Realm, concluded that MI5 did not use the information to undermine Wilson - despite his fears in his later years that they were plotting to oust him.
According to the book, to be published next week to mark the service's centenary, MI5 first opened the file on Wilson because of concerns about his relationships with Eastern European businessmen, including the Lithuanian Joseph Kagan, whose company made his trademark Gannex macs.
Wilson was also said to have had contacts with known KGB officers while comments made about him by communist members of the Civil Service were said to have "suggested an identity or similarity of political outlook".
The sensitivity of the file was such that it was kept in under the pseudonym "Norman John Worthington". In the early 1970s, the then director general, Sir Michael Hanley, took further steps to conceal its existence.
"In March 1974, the DG instructed that the card referring to the file should be removed from the registry central index, with the result that 'a look-up on Harold Wilson would therefore be No Trace'," the book states.
During his final years in office, an increasingly paranoid Wilson made repeated claims to associates that he was being bugged by MI5 - an assertion dismissed by Mr Andrew, who had full access to the service's files.
"Though MI5 was not, of course, listening in to the prime minister and had never actively investigated him, it still had a file on him which recorded, inter alia, his past contacts with communists, KGB officers and other Russians," he wrote.
Mr Andrew also rejects the claims by former MI5 officer Peter Wright in his book, Spycatcher, that members of the service had conspired to force Wilson to stand down.
"There was, in reality, no plot by any service officer, serving or retired, to conspire against Wilson," he wrote.
Join our commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies