Classical ciphers
Interactive, step-by-step visualizations of five classical ciphers: Caesar, Atbash, Vigenère, keyword substitution and rail fence.
Substitution
Every letter is replaced by another letter.
Caesar cipher
Shift every letter a fixed number of places down the alphabet.
Open visualizerAtbash cipher
Mirror the alphabet: A becomes Z, B becomes Y, and so on.
Open visualizerKeyword substitution
Scramble the alphabet with a keyword and swap each letter for its partner.
Open visualizerVigenère cipher
A repeating keyword picks a different Caesar shift for each letter.
Open visualizerTransposition
The letters stay the same, only their order changes.
How it is broken
How every one of them fell
These ciphers protected real secrets for centuries. Each was broken by one of two ideas, and modern cryptography is designed against both.
25keys
Try every key
A Caesar shift has only 25 useful keys and a rail fence a handful. Trying them all takes seconds by hand.
Brute force and key sizeEmost common letter
Count the letters
Substitution keeps each letter’s frequency: the most common symbol is probably E. Even 26! ≈ 4 × 10²⁶ keys don’t help.
Crack Caesar and Vigenère128bits, mixed
What changed
AES has 2¹²⁸ keys and mixes every bit with every other, so no letter, pattern or frequency survives encryption.
See inside AES