Accounts differ as to the cause of death; one version stated that he died by poison only and another view claimed he died by a self-inflicted gunshot while biting down on a cyanide capsule. Contemporary historians have rejected these accounts as being either Soviet propaganda or an attempted compromise in order to reconcile the different conclusions. One eyewitness stated that Hitler's corpse showed signs of having been shot through the mouth, but this has been proven unlikely. There is also controversy regarding the authenticity of skull and jaw fragments that were recovered. In 2009, American researchers performed DNA tests on a skull fragment that Soviet officials had long believed to be that of Hitler. The DNA tests and examination revealed that the skull was actually that of a woman less than 40 years old. The recovered jaw fragments were not tested.
By early 1945, Germany's military situation was on the verge of total collapse. Poland had fallen to the advancing Soviet forces, who were, by then, preparing to cross the Oder between Küstrin and Frankfurt with the objective of capturing Berlin, 82 kilometres (51 mi) to the west. German forces had recently lost to the Allies in the Ardennes Offensive, with British and Canadian forces crossing the Rhine into the German industrial heartland of the Ruhr. American forces in the south had captured Lorraine and were advancing towards Mainz, Mannheim, and the Rhine. In Italy, German forces were withdrawing north, as they were pressed by the American and Commonwealth forces as part of the Spring Offensive to advance across the Po and into the foothills of the Alps. In parallel to the military actions, the Allies had met at Yalta between 4–11 February to discuss the conclusion of the war in Europe.
Presiding over a rapidly disintegrating Third Reich, Hitler retreated to his Führerbunker in Berlin on 16 January 1945. It was clear to the Nazi leadership that the battle for Berlin would be the final battle of the war in Europe. Some 325,000 soldiers of Germany's Army Group B were surrounded and captured on 18 April, leaving the path open for American forces to reach Berlin. By 11 April the Americans crossed the Elbe, 100 kilometres (62 mi) to the west of the city. On 16 April, Soviet forces to the east crossed the Oder and commenced the battle for the Seelow Heights, the last major defensive line protecting Berlin on that side. By 19 April the Germans were in full retreat from Seelow Heights, leaving no front line. Berlin was bombarded by Soviet artillery for the first time on 20 April (Hitler's birthday). By the evening of 21 April, Red Army tanks reached the outskirts of the city.
At the afternoon situation conference on 22 April, Hitler suffered a total nervous collapse when he was informed that the orders he had issued the previous day for SS-General Felix Steiner's Army Detachment Steiner to move to the rescue of Berlin had not been obeyed. Hitler launched a tirade against the treachery and incompetence of his commanders; his outburst culminated in a declaration—for the first time—that the war was lost. Hitler announced that he would stay in Berlin until the end and then shoot himself. Later that day he asked SS physician Dr. Werner Haase about the most reliable method of suicide. Haase suggested the "pistol-and-poison method" of combining a dose of cyanide with a gunshot to the head. When the head of the Luftwaffe, Reichsmarschall Hermann Göring, learned about this, he sent a telegram to Hitler asking for permission to take over the leadership of the Reich in accordance with Hitler's 1941 decree naming Göring his successor. Hitler's influential secretary, Martin Bormann, convinced Hitler that Göring was threatening a coup. In response, Hitler informed Göring that he would be executed unless he resigned all of his posts. Later that day, he sacked Göring from all of his offices and ordered his arrest.
By 27 April, Berlin was cut off from the rest of Germany. Secure radio communications with defending units had been lost; the command staff in the bunker had to depend on telephone lines for passing instructions and orders and on public radio for news and information. On 28 April, a BBC report originating from Reuters was picked up; a copy of the message was given to Hitler. The report stated that Reichsführer-SS Heinrich Himmler had offered to surrender to the western Allies; the offer had been declined. Himmler had implied to the Allies that he had the authority to negotiate a surrender; Hitler considered this treason. During the afternoon his anger and bitterness escalated into a rage against Himmler. Hitler ordered Himmler's arrest and had Hermann Fegelein (Himmler's SS representative at Hitler's headquarters in Berlin) shot.
By this time, the Red Army had advanced to the Potsdamerplatz, and all indications were that they were preparing to storm the Chancellery. This report, combined with Himmler's treachery, prompted Hitler to make the last decisions of his life. After midnight on 29 April, Hitler married Eva Braun in a small civil ceremony in a map room within the Führerbunker. Afterwards Hitler hosted a modest wedding breakfast with his new wife. Hitler then took secretary Traudl Junge to another room and dictated his last will and testament. He signed these documents at 04:00 and then retired to bed (some sources say Hitler dictated the last will and testament immediately before the wedding, but all sources agree on the timing of the signing).
During the course of 29 April, Hitler learned that his ally, Benito Mussolini, had been executed by Italian partisans. The bodies of Mussolini and his mistress, Clara Petacci, had been strung up by their heels. The corpses were later cut down and thrown into the gutter, where vengeful Italians reviled them. These events probably strengthened Hitler's resolve not to allow himself or his wife to be made "a spectacle of", as he had earlier recorded in his Testament. That afternoon, Hitler expressed doubts about the cyanide capsules he had received through Himmler's SS. To verify the potency of the capsules, Hitler ordered Dr. Werner Haase to test one on his dog Blondi, who died as a result.