After graduation from high school in 1907, Yardley went to the University of Chicago, but dropped out after one year and went back to Worthington, where he worked as a telegrapher for a railroad.
He accepted a Signal Corps Reserve commission and served as a cryptologic officer with the American Expeditionary Forces in France during World War I.
American participation in the war gave Yardley an opportunity to convince Major Ralph Van Deman of the need to set up a section to break other countries' codes.
In June 1917, Yardley became a 2nd lieutenant in the Signal Corps and head of the newly created eighth section of military intelligence, MI-8.
[4] One early case was the cryptogram discovered in the clothing of German spy Lothar Witzke after he was arrested at the Mexican border in 1918.
The evidence linked Witzke to significant sabotage activity in the U.S. Yardley proved to be a very good administrator and during the war the people of MI-8 performed well even if they did not have any spectacular successes.
After the war, the American Army and the State department decided to jointly fund MI-8 and Yardley continued as head of the "Cipher Bureau".
[7] Upon finding out about Yardley and the Cipher Bureau, Stimson was furious and withdrew funding, summing up his argument with "Gentlemen do not read each other's mail.
[7][10] In 1929, President Herbert E. Hoover's new secretary of state, Henry L. Stimson, was provided with a few selected translations so he could become acquainted with the Black Chamber's skills.
With Yardley's esoteric skills in very low demand, and no government pension due to his secretly funded work, he took up writing about his experiences in codebreaking to support his family.
Its critics at the time concluded that it was "the most sensational contribution to the secret history of the war, as well as the immediate post-war period, which has yet been written by an American.
Much of the post-World War I codebreaking was done by obtaining copies of enciphered telegrams sent over Western Union by foreign diplomats, as was the custom before countries had technology for specialized communications devices.
William F. Friedman, considered the father of modern American signals intelligence (SIGINT) gathering, was incensed by the book and the publicity it generated in part because sources and methods were compromised and because Yardley's contribution was overstated.
While Yardley may have thought that publishing this book would force the government to re-establish a SIGINT program, it had the opposite effect.
The American Black Chamber represents an early example of the exposé national security books that would appear after World War II, such as The Codebreakers and The Puzzle Palace, which also focus on U.S. SIGINT operations and organizations.
He contributed as a writer and technical advisor to several movies, including Rendezvous, based very loosely on one of his novels, The Blonde Countess.
The National Cryptologic Museum's library has 16 boxes of intercepted messages and translations from the Cipher Bureau, previously misidentified as Yardley's personal papers.