For almost 60 years, the evidence of Britain's clandestine torture programme in postwar Germany has lain hidden in the government's files. Harrowing photographs of young men who had survived being systematically starved, as well as beaten, deprived of sleep and exposed to extreme cold, were considered too shocking to be seen.

As one minister of the day wrote, as few people as possible should be aware that British authorities had treated prisoners "in a manner reminiscent of the German concentration camps".

Many other photographs known to have been taken have vanished from the archives, and even this year some government officials were arguing that none should be published.

The pictures show suspected communists who were tortured in an attempt to gather information about Soviet military intentions and intelligence methods at a time when some British officials were convinced that a third world war was only months away.

Others interrogated at the same prison, at Bad Nenndorf, near Hanover, included Nazis, prominent German industrialists of the Hitler era, and former members of the SS.

At least two men suspected of being communists were starved to death, at least one was beaten to death, others suffered serious illness or injuries, and many lost toes to frostbite.

The appalling treatment of the 372 men and 44 women who were interrogated at Bad Nenndorf between 1945 and 1947 are detailed in a report by a Scotland Yard detective, Inspector Tom Hayward. He had been called in by senior army officers to investigate the mistreatment of inmates, partly as a result of the evidence provided by these photographs.

Insp Hayward's report remained secret until last December, when the Guardian secured its release under the Freedom of Information Act. The photographs seen here were removed before the Foreign Office released the report, apparently because the Ministry of Defence did not wish them to be published. That decision was reversed last week, following an appeal by the Guardian.

One of the men photographed, Gerhard Menzel, 23, a student, was arrested by British intelligence officers in Hamburg in June 1946. He had fallen under suspicion because he was believed to have travelled to the British-controlled zone of Germany from Omsk in Siberia, where he had been a prisoner of war. His weight, measured several weeks after his arrest at 10st 3lb, had fallen to 7st 10lb by the time he was transferred from Bad Nenndorf to a British-run internment camp eight months later.

In the meantime, he told Hayward, his hands had been chained behind his back for up to 16 days at a time, periods during which he was repeatedly punched in the face. He had also been held in a bare, freezing cell for up to two weeks at a time and doused in cold water every 30 minutes from 4.30am until midnight, a practice the detective discovered to have been common.

A doctor at the internment camp reported that Mr Menzel was one of a group of 12 inmates transferred from Bad Nenndorf, all emaciated and dressed in rags. Previous arrivals had also been half-starved. Some had facial scars, apparently the result of beatings. A few had scars on their shins, said to be the result of torture with shin screws which had been retrieved from a Gestapo prison at Hamburg.

Mr Menzel "was only skin and bones," the doctor wrote. "He could neither walk nor stand up without assistance, and could only speak with difficulty because his tongue and lips were swollen and broken open.

"It was impossible to take his body temperature because it was not higher than 35 degrees Celsius and the thermometer only starts at 35."

The prisoner was also confused, anxious and suffering memory loss, his lungs were badly infected and his blood pressure was dangerously low. Only after being washed, fed and heated with lamps could his body temperature be raised to 36.3C, but the doctor feared his chances of survival were slim.

Another man pictured, Heinz Biedermann, 20, a clerk, had been arrested in October 1946 because he was in the British zone, while his father, who lived at Stendal in the Russian zone, had been identified as "an ardent communist". By the time he was transferred from Bad Nenndorf four months later his weight had fallen from 11st 3lb to 7st 12lb. He said he had been held in solitary confinement for much of the time, threatened with execution, and forced to live and sleep in sub-zero temperatures while barely clothed.

One British army guard told Inspector Hayward that Mr Biedermann had "wasted like a candle" during his imprisonment. Another, a private in the Essex Regiment, told the detective that he complained that he and his comrades were behaving as badly as Germans. "I became very unpopular after this ... the sergeant appeared to take a poor view of my remarks."

On Mr Biedermann's transfer to the internment camp, an officer at Bad Nenndorf requested he be detained "for an adequate time" to prevent him giving the Soviets "detailed information on this centre and methods of interrogation".

Foreign Office records show that the navy officer commanding the internment camp, Captain Arthur Curtis, was so shocked by the condition of the men being sent to him that he ordered these photographs be taken to support his complaints about the treatment of these "living skeletons". Photographs of several other prisoners, taken at the same time, appear to have vanished from the Foreign Office files.

On the other side of the British zone, meanwhile, a Royal Artillery officer was complaining about the state of Bad Nenndorf inmates who were being dumped from a truck at the entrance to a military hospital. Some weighed little more than six stones, and two died shortly after their arrival.

The records show that Bad Nenndorf was run by a War Office department called the Combined Services Detailed Interrogation Centre (CSDIC).

By late 1946, CSDIC appears to have lost interest in Nazis, and was targeting communists. It appears the prisoners were questioned about Soviet methods and intentions, rather than about the Communist party itself.

Some of Bad Nenndorf's inmates were indeed spying for the Soviets: one prisoner, who was half-Norwegian and half-Russian, told Hayward he was an officer in the NKVD, the predecessor of the KGB, and had been operating continuously in Germany since 1938. Another, a German journalist who had been freed by the Soviets from a Gestapo prison, was caught flying into Croydon aerodrome with false British papers. Both men were starved and badly tortured.

Others clearly were not spies, however. One man who was starved to death was a gay ex-soldier caught with forged papers while crossing into the British zone in search of his lover, while the other was a young German who was being interrogated because he had volunteered to spy for the British in the Russian zone, and was wrongly suspected of lying because of an official error over his medical records.

Four British officers were court martialled after Hayward's investigation. Declassified documents show that the hearings were held largely behind closed doors to prevent the Soviets from discovering that Russians were being detained.

Another consideration was admitted to be the determination to conceal the existence of several other CSDIC prisons. While it is now known that one interrogation centre was in central London, little is known about those in Germany, other than their locations.

Following the courts martial, the prison at Bad Nenndorf, which was in a converted bath-house, was replaced with a purpose-built interrogation centre near an RAF base at Gütersloh, and orders were issued for inmates to be examined by a doctor before interrogation. It is unclear when this centre closed.

The only officer at Bad Nenndorf to be convicted was the prison doctor. At the age of 49, his sentence was to be dismissed from the army. The commanding officer, Colonel Robin Stephens, was cleared of a charge of "disgraceful conduct of a cruel kind" and told he was free to apply to rejoin his former employers at MI5.