← All tools
// Security

Caesar Cipher online

Encrypt and decrypt text with the classic Caesar shift cipher

Caesar Cipher logo
by
CHUNKY
MUNSTER
// Input text
// Output

How to Use caesar-cipher

  1. Enter the text you want to encrypt in the input field.
  2. Set the shift value (1–25) using the slider or number input.
  3. Click Encrypt to shift each letter by the chosen amount.
  4. Use Decrypt — or simply shift by (26 − key) — to reverse the process.

The Caesar cipher is the simplest substitution cipher: each letter is shifted a fixed number of positions forward in the alphabet. Julius Caesar reportedly used a shift of 3 — A becomes D, B becomes E, and so on. It is trivially breakable by trying all 25 possible shifts, but it is still widely used in CTF (capture-the-flag) challenges, puzzles, and as a teaching example for cryptography concepts.

Breaking Caesar Cipher: Frequency Analysis

With only 25 possible keys, brute force is trivial — this tool shows all 25 decryptions simultaneously in the "Brute Force" tab. Frequency analysis is even faster: in English, E is the most common letter (~12.7%), followed by T (~9.1%), A (~8.2%), O (~7.5%). In the ciphertext, whichever letter appears most frequently is likely E — the shift between them is the key.

Frequently Asked Questions

Why is Caesar cipher not secure?

It has only 25 possible keys. A computer can try every one in microseconds. Even by hand, frequency analysis breaks it quickly. It provides no security against any attacker.

What is ROT13?

ROT13 is a Caesar cipher with shift 13. Because 26/2 = 13, ROT13 is its own inverse — applying it twice returns the original text. It is used on some forums to hide spoilers.

How do spaces and punctuation behave?

Only alphabetic characters are shifted. Spaces, digits, punctuation, and other characters are left exactly as-is, which itself is an information leak (word lengths are visible).

What is the difference between Caesar cipher and Vigenère?

Caesar uses one shift value for the entire message. Vigenère uses a keyword where each letter sets the shift for the corresponding plaintext letter — making frequency analysis much harder.

See also the Vigenère Cipher, AES Cipher, and XOR Encryptor for stronger encryption options.