Home / Caesar cipher encoder and decoder
Caesar cipher encoder and decoder
Updated December 3, 2026
Pick a shift and type text on the left to encode it, or paste coded text on the right to decode it. Below, all 26 shifts of the right-hand text are listed.
How it works
The Caesar cipher replaces each letter with the one a fixed number of places further along the alphabet, wrapping from Z back to A. Encoding with a shift of 3 turns A into D, and decoding shifts back. Only the letters A to Z are changed; case is kept, and digits, spaces and punctuation are left alone.
| Plain | Shift 3 | Shift 13 | Plain | Shift 3 | Shift 13 |
|---|---|---|---|---|---|
| A | D | N | N | Q | A |
| B | E | O | O | R | B |
| C | F | P | P | S | C |
| D | G | Q | Q | T | D |
| E | H | R | R | U | E |
| F | I | S | S | V | F |
| G | J | T | T | W | G |
| H | K | U | U | X | H |
| I | L | V | V | Y | I |
| J | M | W | W | Z | J |
| K | N | X | X | A | K |
| L | O | Y | Y | B | L |
| M | P | Z | Z | C | M |
Example
With a shift of 5, “Attack at dawn” becomes Fyyfhp fy ifbs. A is 5 places before F, t is 5 places before y, and the w in dawn goes to b because the alphabet wraps around after z.
When you do not know the shift
Paste the coded text in the right-hand box and look at the table of all 26 shifts that appears below the boxes. There are only 25 useful shifts (shift 0 changes nothing), so trying every one and reading down to the line that makes sense is a complete attack on this cipher. That is why it is a puzzle and not a way to keep secrets. The guide to the Caesar cipher and ROT13 shows a worked example, and ROT13 has its own page.
Questions
Which shift did Julius Caesar use?
According to the Roman historian Suetonius, he used a shift of three, so that A became D when encrypting.
Does it change numbers or punctuation?
No. Only letters move. Numbers, spaces and punctuation stay as they are.
Is this secure?
No. With only 25 possible shifts, anyone can try them all in a minute, so use it for puzzles and learning only.