Skip to content

Caesar Cipher Encoder & Decoder

Encode and decode Caesar shift ciphers with any shift from 1 to 25, including ROT13. Letters keep their case, and everything that is not a letter passes through unchanged.

Mode

How the Caesar Cipher Works

The Caesar cipher is one of the oldest known encryption techniques, named after Julius Caesar, who used it around 58 BC to protect military correspondence. Each letter is replaced by the letter a fixed number of positions further along the alphabet, wrapping around from Z back to A. With a shift of 3, HELLO becomes KHOOR.

Decoding simply shifts in the opposite direction. Because there are only 25 meaningful shifts, the cipher offers no real security today — but that same weakness makes it a perfect introduction to cryptography, and the brute-force mode above shows exactly how an attacker would break it.

Frequently Asked Questions

What is a Caesar cipher?
A Caesar cipher is a substitution cipher that shifts every letter of the alphabet by a fixed number of positions. With a shift of 3, A becomes D, B becomes E, and so on, wrapping around from Z back to A. It is named after Julius Caesar, who reportedly used it for military messages.
How do I decode a Caesar cipher without knowing the shift?
Enable the brute-force mode. It applies all 25 possible shifts to your message at once, so you can scan the list and spot the one that reads as plain English. Because there are only 25 possibilities, a Caesar cipher is always breakable this way.
What is ROT13?
ROT13 is a Caesar cipher with a shift of exactly 13. Because the alphabet has 26 letters, applying ROT13 twice returns the original text — the same operation both encodes and decodes. Click the ROT13 preset button to set the shift to 13.
Does the cipher change numbers, spaces, or punctuation?
No. Only the letters A-Z and a-z are shifted. Digits, spaces, punctuation, and any other characters pass through unchanged, and the tool preserves the original upper- and lowercase of every letter.
Is a Caesar cipher secure?
No. With only 25 possible keys it can be broken in seconds by trying every shift, which is exactly what the brute-force mode does. It is great for puzzles, games, and learning about cryptography, but never use it to protect real secrets.

Related Tools