I first met Edward Teller, the Hungarian-born physicist and father of the H-bomb, while researching a television series about Robert Oppenheimer. Teller was seen as the embodiment of Dr Strangelove, the eponymous scientist in Stanley Kubrick's classic black comedy, and though he hated the association, it seemed appropriate enough.

In the luxurious house of a friend of Teller's in downtown Hollywood, the scriptwriter Peter Prince and I listened while Teller delivered an impassioned monologue justifying his actions over the Oppenheimer affair (of which more later). His words were given additional weight by his rich, Bela Lugosi baritone and we left feeling we had experienced something of the force of personality that had prevailed for 50 years over congressmen, generals and presidents. It was that meeting that drew me to write Teller's biography.

The Americans detonated the first deliverable form of the H-bomb on Bikini atoll 50 years ago this month. It was thanks to Teller that the original discoveries were made that led to the bomb. He also pushed hard to develop the weapon, establishing his own lab, the Lawrence Livermore near San Francisco. In doing so, he quickly became the eminence grise behind one of America's key weapons laboratories.

When I started work on the biography, I had in mind the trenchant and damning comment of Isidor Rabi, the Nobel Prize-winning physicist. He knew the murky world of nuclear power politics, yet still described Teller as "a danger to all that is important" and "an enemy of humanity".

But then I came across the letters Teller had written over two decades to Maria Mayer, a fellow physicist, which he did not know she had kept until a few years ago. They revolutionised my view of him. I was touched by his rootlessness - the fact that the military housing of wartime Los Alamos was more home to him than anywhere. I was surprised by his continual dissatisfaction with himself, and his vulnerability to the opinions of others. There was an obvious dichotomy between the private and public man to be explored here and an examination of Teller's record soon exposed the reasons for Rabi's strong feelings.

As well as "fathering" the H-bomb, it was at Livermore that Teller initiated the Polaris programme, which revolutionised nuclear strategy by producing warheads small enough to be launched from ever-elusive submarines. It was here also, during Eisenhower's presidency, that Teller generated a stream of technical objections why it would be impossible to maintain and monitor a test ban with an enemy as devious as the Soviets. In doing so he thwarted Eisenhower's dream of a test-ban to end the arms race. If Teller had trusted the Russians to negotiate the world may have been spared the trauma of the Cuban missile crisis.

As if this were not enough, it was at Livermore that Teller initiated work on Excalibur, the space-based laser which he sold to President Reagan as the ultimate shield against missile attack, and which many authoritative critics believed was nothing more than a wasteful fantasy. The mantle of Dr Strangelove seemed to slip easily over Teller's shoulders.

For much of his life, Teller also bore another stigma for having betrayed Robert Oppenheimer, the wartime director of the Manhattan Project's bomb laboratory at Los Alamos. Fifty years ago on 12 April, Oppenheimer faced a security hearing where he was accused of being a Soviet spy. Teller testified against him. It ended Oppenheimer's career but it damaged Teller as well. Once his role in the affair became known to colleagues, he was professionally exiled. He declared he was "more miserable than I had ever been before in my entire life".

But was his reaction just self-pity at the plight he had created or something more that reflected his past?

Looking at his own strikingly honest account, Teller's childhood was not a happy one. He was born in Budapest in 1908 to Jewish parents, who were hugely protective. He recalled one incident when his mother took him and his sister swimming at a lido. While other children were diving into the water, his mother sat on the bank "rigidly holding the end of the cord she had tied around the waist of each of us". He was educated at home and when eventually he went to school, he was teased and bullied mercilessly. For five years he was an outsider, finding friends only a few years before university. As a student moving around Europe from one centre of excellence in physics to another, he was again in fear of becoming an outcast.

Perhaps not surprisingly, the happiest years of his life were those immediately following his emigration to the US in 1935, when he found himself a big fish in the little pond that was American physics. He had status and he blossomed, esteemed for Nobel quality research, and for his generosity in helping others.

It was in this spirit that he joined America's nuclear bomb programme, where he began working with Oppenheimer. Oppenheimer had a reputation for arrogance, but initially the two men got on well. Teller in fact, basked in the relationship and helped with setting up the famous Los Alamos laboratory. Because of his efforts, Teller hoped to become the head of the theoretical division. Oppenheimer, however, chose Hans Bethe, Teller's close friend. Teller was devastated. In retrospect, Bethe sees it as a turning point, an end to the "gentle Teller" of the pre-war years and a point of no return in the relationship between Teller, Oppenheimer and himself.

Over the next decade, as he struggled with all the technical and political problems with the H-bomb, Teller became increasingly touchy and difficult, seeing enemies at every turn. By the time the H-bomb had been accepted, Teller firmly believed that Oppenheimer had been orchestrating a campaign against it. In 1952, when his anger and bitterness were at their height, he told the FBI of his feelings. The FBI added his complaints to the dossier they already had on Oppenheimer and in 1954 they formed the major charges against him at his hearing. When the transcript, initially intended to be secret, was published, Teller's handiwork was revealed for all to see and his "exile" began.

It nearly broke him. Both he and his wife, Mici, were seriously ill and Teller himself came close to suicide. Teller's rejection must have opened old wounds from his youth. They were exacerbated by a deep sense of injustice. He believed he had achieved a great deal, and had ensured that, in the H-bomb, his adopted country had a class of weapon as different in destructive power from fission weapons as these were from conventional weapons.

Teller believed in "peace through strength" and argued he did not "want a hydrogen bomb because it would kill more people" but because once "a development is possible it is out of our powers to prevent it". So the race to be first had to be joined. He described as "romantic" Oppenheimer's line which renounced "particular weapons as immoral precisely because they are most powerful [while] at the same time an amoral society deploys and is ready to use those weapons."

The amoral society was, of course, Russia, and Teller had a deep mistrust of the country from his Hungarian childhood. While Stalin was still in the Kremlin, he shared his mistrust with millions and was lionised for his work on the H-bomb. However, as tensions between East and West eased, Teller conceded nothing. So uncompromising did he appear that, whatever his moral stance, his actions were interpreted as the very obsession Kubrick had targeted in Dr Strangelove.

But there is another interpretation of Teller's actions other than obsession. Teller had known power and had developed strategies necessary to generate political action. He exaggerated the dangers or the virtues of projects, often shamelessly. His exaggerations were often exposed but his reputation and political alliances meant that he was still listened to. How this worked can be seen in what happened during the early 1980s with the strategic defence initiative (SDI), popularly known as"star wars", and its role assisting in the break-up of the Soviet Union.

SDI consisted of a number of projects aimed at producing a defensive shield against missile attack. One project, Excalibur, was based on converting energy from a small H-bomb into powerful X-ray laser beams that would destroy enemy missiles in space. The experimental justification was elementary to say the least, but Teller described it as "a laser module the size of an executive desk" producing thousands of focused laser beams which "could potentially shoot down the entire Soviet land-based missile force". It was an incredible claim, heavily criticised by other scientists, but Reagan wanted to believe Teller's concept and so the administration adopted it as the President's "vision".

Even more amazingly, the Soviets took it so seriously that when Reagan first announced it, they came close to launching a pre-emptive nuclear attack. What happened when Gorbachev came to power was even more extraordinary. At the 1986 Reykjavik summit, amazed veteran negotiators watched as Gorbachev offered to eliminate all nuclear weapons if SDI were confined to the lab for 10 years. In the end his attempt failed, paradoxically because Reagan would not give up the real SDI, but it led to a whole different phase in East-West relations.

Teller, who died late last year, knew how to influence politics. He knew it was more like magic than logic, and in spinning his spells, he was both dishonest, wasteful, and at times dangerous. He never saw this as evil or immoral. He once corrected Oppenheimer's famous comment that "scientists have known sin". As far as Teller was concerned "scientists have known power" and what it demands.

· To order a copy of Edward Teller, The Real Dr Strangelove by Peter Goodchild, for £17 plus p&p (rrp £20), call the Guardian book service on 0870 0667979. Published by Weidenfeld