Caesar Cipher

Encrypt and decrypt text with any shift value — the classic cipher used by Julius Caesar.

Loading tool…

Encrypt and decrypt with the Caesar cipher

The Caesar Cipher tool shifts each letter of your message by a chosen number of places to encrypt it, and shifts back to decrypt. Pick any shift from 1 to 25, switch between encrypt and decrypt, and copy the result instantly. It is a fun, hands-on way to explore one of history's oldest ciphers — all running privately in your browser.

What is the Caesar cipher?

Named after Julius Caesar, who reportedly used it for military messages, the Caesar cipher is a substitution cipher that replaces each letter with one a fixed number of positions down the alphabet. With a shift of 3, A becomes D, B becomes E, and Z wraps around to C. Decrypting simply shifts in the opposite direction. The "ROT13" cipher is just a Caesar cipher with a shift of 13.

How to use it

  1. Choose Encrypt or Decrypt.
  2. Set the shift value (the secret "key").
  3. Type your message and copy the result.

Example with shift 3

PlainEncrypted
HELLOKHOOR
attack at dawndwwdfn dw gdzq

How secure is it?

The Caesar cipher is easy to break and offers no real security — there are only 25 possible shifts, so an attacker can simply try them all in seconds. Letter-frequency analysis cracks it even faster. Its value today is educational: it is the perfect introduction to encryption concepts like keys, substitution, and brute-force attacks. For genuine security, use modern encryption, not a shift cipher.

Tips and trivia

  • Only letters are shifted — numbers, spaces, and punctuation stay the same.
  • A shift of 13 is ROT13, which is its own inverse.
  • To crack an unknown Caesar cipher, try each shift and look for readable text.
  • The cipher wraps around the alphabet, so Z + 1 becomes A.

Private and free

All encryption and decryption happen in your browser, with nothing uploaded and no limits. Use it as much as you like, free.

Frequently asked questions

How does the Caesar cipher work?

It shifts each letter by a fixed number of positions in the alphabet. With shift 3, A becomes D. Decrypting shifts back.

Is the Caesar cipher secure?

No. With only 25 possible shifts it is trivial to brute-force. It is for learning and fun, not real security.

What is the relationship to ROT13?

ROT13 is a Caesar cipher with a shift of 13, which happens to be its own inverse.

Does it affect numbers and punctuation?

No. Only letters are shifted; numbers, spaces, and symbols are left unchanged.