How to Crack a Caesar Cipher — Brute Force & Frequency Analysis

By Letters2NumbersConverter.com | May 13, 2026

The Caesar cipher has only 25 possible keys — making it one of the easiest classical ciphers to crack. This guide walks through both methods: brute force (try all 25 shifts until one produces readable text) and frequency analysis (use the statistical distribution of letters to identify the shift mathematically). Both methods work without any specialist tools, though our free Caesar Cipher Decoder automates the entire process with a single click.

Why the Caesar Cipher Is Easy to Crack

Every Caesar cipher has a key space of exactly 25 (shifts 1 through 25 — shift 0 and shift 26 are the same as no shift). A human can read through 25 candidate decryptions in about two minutes. A computer can check all 25 in microseconds.

The 9th-century Arab mathematician Al-Kindi identified this weakness in his treatise on cryptanalysis, and the Caesar cipher has been considered broken — in the cryptographic sense — for over 1,000 years. It is taught today as an educational tool, not a security system.

Method 1: Brute Force — Try All 25 Shifts

The simplest approach is to decode the ciphertext with every possible shift from 1 to 25 and look for the one that produces readable English.

Step-by-Step: Brute Force

  1. Write down the ciphertext. You need the full encoded message.
  2. Attempt shift 1. Replace each letter with the letter 1 position earlier in the alphabet (A→Z, B→A, C→B, etc.). Does the result look like readable text?
  3. If not, try shift 2, shift 3, and so on. For most English text, the correct shift stands out immediately — the decrypted words will be recognisable.
  4. Stop when you find readable text. That shift is the key.

Worked Example: Brute Force

Ciphertext (shift 11 applied):

HSPY TY ESP NZFCDP ZQ SFXLY PGPYED TE MPNZXPD YPNPDDLCJ

Trying a few shifts manually:

Shift 1GROX SX DRO MYEBCO YP REWKX OFOXDC SD LOMYWOC XOMO
Shift 3EPMV QV BPM KWCZAM WN PCUIV MDMVBA QB JMKWUMA VMKM
Shift 7ALIR MR XLI GSYVWI SJ LYQER IZIRXW MX FIGSQIW RIGI
★ Shift 11WHEN IN THE COURSE OF HUMAN EVENTS IT BECOMES NECE
Shift 13UFCL GL RFC AMSPQC MD FSKYL CTCLRQ GR ZCAMKCQ LCAC

Shift 11 immediately produces recognisable English — the correct key is found. Our Caesar Cipher Decoderdoes this automatically: click "Show all 25 shifts" and the correct decryption is ranked first.

Method 2: Frequency Analysis — The Mathematical Approach

Frequency analysis works because letters in natural language do not appear with equal probability. In English, E appears in roughly 12.7% of all letters. T, A, O, I, and N are the next most frequent. Z, Q, X, and J appear rarely.

When you apply a Caesar cipher, the relative frequencies shift along with the letters. The most common letter in the ciphertext is almost certainly the encoded version of E. Finding it tells you the shift directly.

English Letter Frequency Chart

E
12.7%
T
9.1%
A
8.2%
O
7.5%
I
7%
N
6.7%
S
6.3%
H
6.1%
R
6%
D
4.3%

Top 10 letters shown. Full alphabet: E T A O I N S H R D L C U M W F G Y P B V K J X Q Z

Step-by-Step: Frequency Analysis

  1. Count how often each letter appears in the ciphertext. Tally every A through Z.
  2. Find the most frequent letter. In a sufficiently long ciphertext (50+ letters), this is very likely the encoded E.
  3. Calculate the shift. If the most common ciphertext letter is P (position 15), and E is position 4, the shift is 15 − 4 = 11.
  4. Verify by decoding. Apply the reverse shift to the ciphertext and check whether it produces readable English.
  5. If it doesn't work, try the second-most-frequent letter. In short texts, the frequency distribution may not match the expected English pattern perfectly. Try assuming the top letter is T, A, O, or I instead.

Worked Example: Frequency Analysis

Using the same ciphertext (shift 11):

HSPY TY ESP NZFCDP ZQ SFXLY PGPYED TE MPNZXPD YPNPDDLCJ

Top 6 most frequent letters in the ciphertext:

P 19.6%
Y 10.9%
D 10.9%
S 6.5%
E 6.5%
N 6.5%

The most frequent letter is P. Assuming this encodes E (position 4):

Shift = position(P) − position(E) = 15 − 4 = 11

→ Shift 11 confirmed ✓

Decoding with shift 11: WHEN IN THE COURSE OF HUMAN EVENTS IT BECOMES NECESSARY

Which Method Should You Use?

SituationBest methodWhy
Short text (< 30 letters)Brute forceFrequency analysis is unreliable on small samples; brute force is fast to scan by eye
Long text (50+ letters)Frequency analysisFrequencies stabilise, giving a reliable shortcut to the correct shift
You have a computerBrute force with scoringA computer checks all 25 shifts instantly and ranks by English score — our tool does this
Puzzle with given hintBrute forceQuicker to try likely shifts first (3, 13, 7, 17) than to count frequencies
Unknown languageBrute forceFrequency analysis depends on knowing the source language's letter distribution

Crack Any Caesar Cipher Instantly — Free Online Tool

Our Caesar Cipher Decoder automates both methods:

  • Paste your ciphertext into the input box
  • Click "Show all 25 shifts" — every possible decryption appears simultaneously, ranked by English-language likelihood score
  • The top result (marked with ★) is almost always the correct one
  • Click the row to apply that shift, or copy the decoded text directly

Limitations of Frequency Analysis on Caesar Ciphers

Frequency analysis becomes unreliable when:

  • The text is very short. A 10-letter ciphertext may not have a clear dominant letter, or the most frequent ciphertext letter may not encode E.
  • The text is a proper noun, list, or unusual vocabulary. A message consisting of place names has a very different frequency distribution from normal prose.
  • The text is a pangram or constrained writing. Some puzzle messages are deliberately constructed to have unusual letter distributions.

In all these cases, fall back to brute force — 25 shifts is a small enough space to check manually or with our tool.

Practice: Crack These Ciphertexts

Try decoding these using our Caesar Cipher Decoder. Use brute-force mode to find each shift.

Puzzle 1

ZNK UTRE CGE UAZ OY ZNXUAMN

Puzzle 2

UDAADL IWT LWXIT GPQQXI

Puzzle 3

GJKSHAZCA EO PDA CNAWPAOP SAWLKJ

Further Reading