Caesar cipher: encode and decode online

Encrypt or decrypt text with a Caesar cipher using any shift, including ROT13.

How to use

Enter text, choose a shift and whether to encrypt or decrypt. Each letter is replaced by the letter a set number of places further along the alphabet (or back, when decrypting). Numbers, spaces and punctuation stay as they are, and upper and lower case are preserved.

Don’t know the key? Choose “Try all shifts”: you’ll see the text at every shift, and the readable one stands out.

Examples

FAQ

How secure is the Caesar cipher? Not at all: there are only 25 possible shifts, so anyone can try them by hand. It’s a teaching and puzzle cipher — great for escape rooms and classrooms. For real protection, use modern encryption and strong passwords.

How do I decrypt without knowing the shift? Switch to “Decrypt” and slide through the shifts — readable text will appear at one of them.

Why did Julius Caesar use a shift of 3? According to the historian Suetonius, Caesar replaced each letter with the one three places after it.