Crack an Enigma Message

2026-05-19

The Inspiration

This project started with a movie. The Imitation Game portrays the nail-biting race against time by Alan Turing and his team at Bletchley Park to crack the German Enigma code during the darkest days of World War II. Benedict Cumberbatch’s portrayal of Turing — brilliant, eccentric, ultimately tragic — sent me down a rabbit hole that ended with building a working simulator of both sides of the story: the machine that encrypted, and the machine that broke it.

Watch the film

The Imitation Game is available on Amazon Prime Video — highly recommended before (or after) playing with the simulator.

The Enigma Machine

Enigma tab — rotor configuration, lampboard, and signal path

The Wehrmacht Enigma produced 158 quintillion possible configurations. Three rotors chosen from five, each at any of 26 starting positions, ring settings that shifted the internal wiring alignment, a reflector that bounced the signal back, and a plugboard that swapped letter pairs — layer upon layer of scrambling that the Germans believed was unbreakable.

Our simulator is historically accurate: real rotor wirings, the double-stepping anomaly, and an animated signal path that traces the electrical current through every stage of the machine. Type a letter and watch it travel through the plugboard, three rotors, the reflector, back through the rotors, and out the other side. No letter ever encrypts to itself — and that single constraint is what made cracking possible.

The Bombe

Bombe tab — menu graph, drum cabinet, BFS depth bar

Turing’s breakthrough was realizing you didn’t need to search the plugboard’s 150 billion configurations. Given a “crib” — a guessed plaintext fragment — you could model the constraints as a graph and propagate hypothetical values through it. Wrong rotor positions contradicted themselves within 3–5 steps. Right ones didn’t.

The simulator shows this in real time: the menu graph lights up during BFS propagation, the 36-drum cabinet highlights which constraints are being tested, and the depth bar shows how quickly each position is eliminated. Most die almost instantly — “FAST REJECT.” When one survives deep checking, you hear a bell. That’s your stop.

The Briefing Room

Briefing tab — Bletchley Park history and operations guide

The app includes a full Briefing tab covering the people and tradecraft behind the codebreaking operation: Rejewski’s Polish foundation, Turing’s menu-graph breakthrough, Welchman’s diagonal board, Knox’s crib-finding discipline, and the Wrens who operated 200+ Bombe machines around the clock.

You’ll also find seven real techniques they used to find cribs — from weather reports and formulaic military language to “gardening” (the RAF deliberately mining specific grid squares to force predictable German transmissions) and “kisses” (cross-network leaks where the same message was encrypted with different keys).

The Poles needed higher mathematics to even begin. Turing made it mechanical. Welchman made it fast. And 10,000 people made it operational. Each layer is impressive on its own — together it’s one of the great intellectual achievements of the 20th century.

Try It Yourself

Quick start

  1. Enigma tab → Click ▶ Load Example
  2. Ciphertext appears → Click Send to Bombe →
  3. Bombe tab → Click ▶ Example Crib → Click Best → Click Start Bombe
  4. Watch the drums spin. Turn on sound (♪ button) for the full effect.

→ Launch the Enigma & Bombe Simulator

See the Real Thing

A fully functional reconstruction of the Turing-Welchman Bombe is on display at The National Museum of Computing in Block H on the Bletchley Park estate in Milton Keynes, England. The reconstruction took 12 years to complete — led by retired engineer John Harper and a team of up to 60 volunteers who re-manufactured most of the one-ton machine’s components from original GCHQ drawings. It contains over 12 miles of wiring, 18,000 drum brushes, and 17,000 screws.

The Bombe sits alongside a working reconstruction of Colossus, the world’s first electronic computer, which broke the even more complex Lorenz cipher used by German High Command. Together, the two machines give visitors an unparalleled look at the wartime code-breaking operation that shortened the war by an estimated two years.

Ruth Bourne, a 92-year-old former Bombe operator, still makes regular appearances at the museum to demonstrate the machine and recall the wartime codebreaking days.

→ Plan a visit to The National Museum of Computing

Further Reading