Müller was a member of the Bavarian People's Party and a close confidant to the last Bavarian prime minister before 1933, Heinrich Held. After Hitler took power he advised the archbishop of Munich, Michael Cardinal von Faulhaber, and also gained the trust of Pope Pius XII, who was elected the successor to Pius XI as head of the Catholic Church on March 2, 1939. In September 1939, the conspirators around Hans Oster and Hans von Dohnanyi asked their colleague Josef Müller to make contact with the British government via the Vatican, in an attempt to end the war. Müller was sent to Rome on behalf of the counterintelligence department and was able to forge links to the British and American governments with the aid of Vatican officials. At the beginning of 1940, Father Robert Leiber helped Josef Müller to ascertain the British government's standpoint and inform his colleagues at the Office for Foreign Affairs/Counterintelligence in the Armed Forces High Command. The conspirators compiled this information from the Vatican for high-ranking officers, in an attempt to win over the Supreme Army Command. Müller was arrested in 1943 and tried by the Reich Court Martial. He survived lengthy Gestapo interrogations and was unexpectedly acquitted. However, Josef Müller remained imprisoned in Buchenwald, Flossenbürg, and Dachau concentration camps. In May 1945, he was part of a group of 139 Sippenhaft and special prisoners liberated by the U.S. Army in Tyrol. After his liberation he was a founding member of the Christian Social Union and one of the first state chairmen for the party.