Caesar Cipher Shifter — ROT-N Text Encoder & Decoder
Encode or decode any message with the Caesar cipher — the substitution cipher Julius Caesar reportedly used. Choose a shift (ROT13 is the most popular), type your text, and get the encrypted or decrypted result instantly. Non-letter characters are left unchanged.
Mode
How does this calculator work?
The Caesar cipher replaces each letter with one N positions later in the alphabet: index = (i + shift) mod 26. Decryption uses the opposite shift. ROT13 (shift 13) is self-inverse. Only letters are shifted — digits, spaces, and punctuation pass through unchanged. Zero real security; purely educational.
Formula
How this is calculated
The Caesar cipher is one of the oldest and simplest encryption techniques. Each letter in the plaintext is replaced by a letter a fixed number of positions later in the alphabet, wrapping around from Z back to A. For example, with a shift of 3, A→D, B→E, …, X→A, Y→B, Z→C. To decrypt, shift in the opposite direction by the same amount (equivalently, shift forward by 26 − shift).
The mathematical operation is modular arithmetic: if a letter has an index i (0 for A, 25 for Z), the cipher replaces it with index (i + shift) mod 26. Uppercase and lowercase letters are shifted independently; numbers, spaces, and punctuation are passed through unchanged.
ROT13 — a shift of 13 — is self-inverse, meaning encrypting twice returns the original text. It is commonly used online to obscure spoilers or mildly sensitive content. ROT5 (shift 5) is sometimes applied to digits. The Caesar cipher provides no real security in modern contexts; it is trivially cracked by frequency analysis or by trying all 25 possible shifts. It is purely educational and recreational.
Frequently asked questions
ROT13 is a Caesar cipher with a shift of 13. Because the English alphabet has 26 letters, applying ROT13 twice returns the original text — it is its own inverse. This makes it convenient for simple obfuscation (spoilers, puzzles) since the same function both encodes and decodes.
No — only the 26 letters of the English alphabet (A–Z, a–z) are shifted. Digits, spaces, punctuation, and Unicode characters outside A–Z are passed through unchanged. A variant called ROT18 extends the shift to digits (A–Z with shift 13, 0–9 with shift 5).
No. With only 25 possible non-trivial shifts, it can be cracked in seconds by trying every shift or by frequency analysis (matching letter frequencies to expected English frequencies). It has no practical security use today — it is purely educational, recreational, and historical.
TG we-Calculate Editorial Team. (2026). Caesar Cipher Shifter — ROT-N Text Encoder & Decoder [Online calculator]. TG we-Calculate. https://we-calculate.com/calculator/caesar-cipher-shifter-calculator
TG we-Calculate Editorial Team. "Caesar Cipher Shifter — ROT-N Text Encoder & Decoder." TG we-Calculate. 2026. https://we-calculate.com/calculator/caesar-cipher-shifter-calculator.
TG we-Calculate Editorial Team, "Caesar Cipher Shifter — ROT-N Text Encoder & Decoder," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/calculator/caesar-cipher-shifter-calculator
@misc{wecalculate_caesar_cipher_shifter_calculator, title = {Caesar Cipher Shifter — ROT-N Text Encoder & Decoder}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/calculator/caesar-cipher-shifter-calculator}}, year = {2026}, note = {TG we-Calculate} }
Did this calculator help you?
