Enigma Machine Simulator Online

Encrypt and decode with Enigma I or M3, using verified rotor stepping and complete machine settings.

By Jack Shi · Updated October 29, 2026

TL;DR: the same settings encode and decode

To decode an Enigma message, enter its ciphertext with the sender’s exact settings and original start positions. Try Enigma I, reflector B, rotors I–II–III, rings AAA, start AAA, and an empty plugboard: AAAAA → BDZGO. Reset to AAA and enter BDZGO to recover AAAAA. The default training message uses a plugboard; load “Five A letters” to try this check directly.

This online Enigma machine supports Enigma I with rotors I–V, and M3 with rotors I–VIII, plus wide reflectors B and C. Both use three moving rotors. You need the sender’s known settings: this simulator does not recover unknown keys or simulate the four-rotor M4.

How to use the simulator

  1. Model: choose Enigma I or M3 to select the available rotor set.
  2. Reflector: match B or C. This setting changes the return path.
  3. Rotors: select three different rotors in left-to-right order; the rightmost rotor is the fast one.
  4. Rings: enter three letters. Convert numbered settings using 01 = A, 02 = B, through 26 = Z; for example 02–21–12 becomes BUL.
  5. Start positions: enter the three window letters shown before the first keypress.
  6. Plugboard: enter space-separated pairs such as AB CD, with each letter used once, or leave it blank.

Choose Encrypt or Decrypt, then type or paste your message. Each edit restarts the entire calculation from your selected windows. Swap puts the output into the input without changing those starting settings. Copy and Download use the displayed result.

Only ASCII letters advance the rotors. Spaces, digits and punctuation stay in place; they are presentation conveniences. Group Letters produces uppercase A–Z in groups of five. For a historical intercept, follow its procedure for the indicator and message key before entering the body; see the Py-Enigma communication example.

Simulator verification

Computed on October 29, 2026: 7 of 7 checks pass. Expected text comes from the linked references or the default training example; Actual is calculated by this simulator. Every row includes the full starting settings and input.

Reference outputs and rotor-window sequences
TestSettings and inputExpectedActualPass
Five A lettersPublished basic vector; step before the electrical path.

Enigma I; reflector B; rotors I–II–III.

Rings AAA; start AAA; plugs none.

Input: AAAAA

BDZGOBDZGOPass
Reference message keyDecrypt the indicator, then reset to BLA for the body.

Enigma I; reflector B; rotors II–IV–V.

Rings BUL; start WXC; plugs AV BS CG DL FU HZ IN KM OW RX.

Input: KCH

BLABLAPass
Reference message bodyPublished teaching example with non-A rings and ten plugboard pairs.

Enigma I; reflector B; rotors II–IV–V.

Rings BUL; start BLA; plugs AV BS CG DL FU HZ IN KM OW RX.

Input: NIBLFMYMLLUFWCASCSSNVHAZ

THEXRUSSIANSXAREXCOMINGXTHEXRUSSIANSXAREXCOMINGXPass
Scharnhorst message excerptFirst 20 letters, using the source’s adjusted rings and message key. Indicator groups already removed.

M3; reflector B; rotors III–VI–VIII.

Rings AHM; start UZV; plugs AN EZ HK IJ LR MQ OT PV SW UX.

Input: YKAENZAPMSCHZBFOCUVM

STEUEREJTANAFJORDJANSTEUEREJTANAFJORDJANPass
Default training messageDefault training settings with ten plugboard pairs.

Enigma I; reflector B; rotors I–II–III.

Rings AAA; start AAA; plugs AV BS CG DL FU HZ IN KM OW RX.

Input: ATTACK AT DAWN

XHZYUG BX VKDRXHZYUG BX VKDRPass
II / III double steppingWindow transitions derived from the published E and V turnover positions.

Enigma I; reflector B; rotors I–II–III.

Rings AAA; start ADU; plugs none.

Input: AAA

ADU → ADV → AEW → BFXADU → ADV → AEW → BFXPass
Published stepping sequenceRijmenants’ published III–II–I sequence.

Enigma I; reflector B; rotors III–II–I.

Rings AAA; start KDO; plugs none.

Input: AAAAAA

KDO → KDP → KDQ → KER → LFS → LFT → LFUKDO → KDP → KDQ → KER → LFS → LFT → LFUPass

A historical message: Scharnhorst

Stefan Krah’s published Scharnhorst break gives the adjusted settings used here: reflector B, III–VI–VIII, rings AHM, message key UZV, plugboard AN EZ HK IJ LR MQ OT PV SW UX. Its first 20 ciphertext letters, YKAENZAPMSCHZBFOCUVM, decode to STEUEREJTANAFJORDJAN. Load “Scharnhorst message excerpt” to reproduce it; the source supplies the complete message and its provenance.

Measured properties: 10,000 letters

0 self-encryptions; 10,000 of 10,000 letters recovered (100%). All 20 of 20 messages round-trip exactly when the original start positions are restored.

The reproducible sample uses xorshift32 with seed 0x454e4947: 20 messages of 500 letters, both models, both reflectors, varied rotor orders, rings and starts, and 0–13 plug pairs. These measurements describe this sample. Download the seven verification results and the sample’s settings, hashes and totals (JSON).

The seven verification rows include their inputs and outputs. The 20 sampled messages are represented by SHA-256 hashes in the JSON. To regenerate those messages and reproduce the totals, download the version 1 generator and source dependencies (ZIP). Extract it, then run node --experimental-strip-types verify.mjs with Node.js 22.6 or later. No package installation or network access is needed; the included README explains how to regenerate both JSON files.

Double-stepping in action

With I–II–III, ring settings AAA and starting windows ADU, the three keypresses below produce ADU → ADV → AEW → BFX. The notch is checked before movement. Rotor III turns its neighbor when leaving V; rotor II turns its neighbor when leaving E. This makes the middle rotor move on two successive presses, as explained in Rijmenants’ stepping mechanism.

Window letters before and after each keypress, left to right
PressBeforeAfterWhy it moves
1ADUADVNeither turnover notch is engaged: only the right rotor advances.
2ADVAEWRight III is at V: middle advances; right advances.
3AEWBFXMiddle II is at E: left and middle advance; right advances.

The ring shifts the wiring relative to the visible alphabet. Since the notch belongs to that alphabet ring, changing rings does not change these turnover window letters. M3 rotors VI, VII and VIII each turn over at both Z and M. Load “Double stepping: ADU” and enter one, two, then three A letters to watch the final windows.

How Enigma encrypts

A keypress advances the rotors before the electrical signal passes through them. The return journey uses each rotor’s inverse wiring, making the complete path reciprocal. The Crypto Museum circuit explanation shows this route through the machine.

Signal path for one letter, after stepping
StagePathEffect
InKey → plugboard → entry wheelSwap a plugged letter; the entry wheel keeps A–Z order.
OutwardRight → middle → left rotorApply three substitutions at the new window positions.
TurnReflector B or CConnect to a different letter and send the signal back.
ReturnLeft → middle → right → entry wheel → plugboard → lampReverse the rotor mappings and apply the plugboard again.
The changing rotor positions make repeated plaintext letters follow different paths.

Why Enigma was breakable

A guessed fragment, or crib, can be aligned with ciphertext. Because Enigma never maps a letter to itself, any alignment containing such a match can be rejected immediately. That narrows a search; it does not reveal the key by itself. Compare letter frequency analysis: moving rotor substitutions do not preserve a simple one-to-one frequency mapping.

Marian Rejewski reconstructed Enigma’s wiring in the Polish Cipher Bureau’s early work; Jerzy Różycki and Henryk Zygalski also developed methods for recovering keys. Crypto Museum’s history traces that breakthrough and the sharing of Polish knowledge with Britain and France.

At Bletchley Park, Alan Turing’s bombe design used cribs to test candidate settings; Gordon Welchman’s diagonal board improved that search. Crypto Museum’s bombe account distinguishes this approach from the earlier Polish bomba. Mathematical structure, message procedures and probable plaintext all mattered.

Frequently asked questions

What is an Enigma machine?

An Enigma machine is an electromechanical rotor cipher machine that encrypts letters by sending a signal through a plugboard, rotating wired rotors, and a reflector.

Can the same Enigma settings decrypt a message?

Yes. Use the same model, reflector, rotor order, ring settings, start positions, and plugboard pairs for encryption and decryption. Reset to the original start positions before processing the ciphertext.

Is Enigma secure for modern use?

No. Enigma is historically important and useful for education, but it is not secure for modern communication or data protection.

How do I decode an Enigma message?

Select Decrypt, match the sender’s model, reflector, rotors, rings, start positions, and plugboard, then paste the ciphertext. This simulator starts afresh on every edit. Historical messages may require decrypting a message key first and removing indicator groups before processing the body.

Why does Enigma never encrypt a letter to itself?

The reflector connects letters in different-letter pairs. The signal travels back through the inverse rotor and plugboard path, so the complete transformation also pairs different letters. A matching plaintext and ciphertext letter therefore rules out that alignment of a guessed fragment.

What is double stepping?

The middle rotor can advance on two consecutive keypresses: once when the right rotor is at its turnover notch, then again when the middle rotor is at its own notch, also moving the left rotor. With rotors I–II–III, the window sequence is ADU → ADV → AEW → BFX.