Author and former West Hampstead resident Doris Lessing was snooped on by spies from MI5 who were concerned about her sympathies with the communist movement.

The much-praised literary figure, who died peacefully at her home in Gondar Gardens, aged 94, in November 2013, was considered one of the most prominent, outspoken and controversial writers of the 20th century.

She moved to London after the Second World War with her mother, who became a nurse at the Royal Free Hospital in Pond Street, Hampstead.

Secret files revealed spooks monitored her phone calls and tracked her travel movements as they investigated how far her left-wing sympathies went.

Lessing, who was awarded the Nobel prize for literature in 2007, was labelled by MI6, the Secret Intelligence Service, as having communist sympathies that bordered on the “point of fanaticism”, and that her opposition of racial discrimination had led to her becoming “irresponsible in her statements”.

Such were the fears about her political leanings that spies eavesdropped on her conversations and those of her friends, tapped phone calls and intercepted her private correspondence.

But some of the surveillance on Lessing - covering the years between 1943 and 1964 in five files - gave more details about her personal life and literary interests than any threat to national security.

The files were among a batch released by the National Archives at Kew, west London, on individuals suspected of being Soviet agents, right-wing extremists or having Russian sympathies during the decades around the Second World War.

They reveal the depths to which police and the security services went in keeping tabs on those they suspected of being communists.

Lessing, born in 1919 in what is now Iran and raised in Southern Rhodesia, now Zimbabwe, joined the Communist Party during the Second World War, partly in reaction to the racism of Rhodesian society.

She roused interest from the security services in the 1940s because of the left-wing views of her second husband, communist activist Gottfried Lessing, and her association with left-wing groups in southern Africa, including the Rhodesian Friends of the Soviet Union.

Marrying him was, she said, her “revolutionary duty”, according to Professor Christopher Andrew, the former official historian of MI5, and she kept his name when their marriage ended and she moved to England in 1949.

But security officials in Britain and Africa had monitored her for a number of years, and regularly corresponded about her activities.

A letter from the Air Ministry in September 1944 revealed concerns among security organisations about those with left-leaning sympathies, noting that the Lessings ran the Salisbury Left Club in Southern Rhodesia, a club “patronised by persons with foreign accents” and RAF personnel.

It said: “The general tone of this club is reported to be very left, and it is stated that most topics of discussion there usually end up in anti-British, anti-capitalist and anti-imperialist vapourings.”

Her travel to the UK in March 1949 was tracked, and MI5 papers disclosed that spies monitored her communications with fellow communists and kept track of her writings for various communist publications.

Scotland Yard’s Special Branch also compiled a file on her in 1950, surveillance was carried out on her address in London and communist friends who visited and stayed with her, and there was even an order to the postmaster-general authorising the inspection of post sent to an address where she stayed in Berlin.

A letter she sent to the Communist Party headquarters in London was intercepted - the files also contained several of her party membership cards - as were minutes of meetings of various left-leaning organisations she was involved in.

But one report from 1952 noted that in letters from Lessing to a male acquaintance, “there does not seems (sic) to be anything strongly suggestive that she is interested in Communism”.

Another detailed concerns about a visit to eastern Germany to meet her former husband and negotiate the production of a play she had written. A note to MI6 stated: “... it is fairly certain from her record that, if not a Party member, she is very close to the Party”.

A later report from Special Branch after Lessing and friends returned from a literary trip to Moscow in July 1952 - which was also closely monitored - revealed their belongings were searched but “revealed nothing of interest”.

And a profile in a report by MI6 that year described Lessing as: “Certainly pro communist, though it (is) doubtful if she is a member of the Party.

“Her communist sympathies have been fanned almost to the point of fanaticism owing to her upbringing in Rhodesia, (which) has brought out in her a deep hatred of the colour bar.

“Colonial exploitation is her pet theme and she has now nearly become as irresponsible in her statements as Coppard saying that everything black is wonderful and that all men and all things white are vicious.”

Files also revealed an account of Lessing’s report at the British Communist Party headquarters in 1956 on the problems in east Africa, Professor Andrew added.

He said: “Later in the same year, outraged by the Soviet invasion of Hungary, Lessing left the party. Her file contains an appeal from party officials for Lessing to withdraw her resignation. She refused.

“Looking back with characteristic honesty on her years in the British Communist Party, during which she was part of an official delegation to Russia, Lessing said later, ‘I can’t understand why I was so gullible’.”