LocalToolkit
HomeEncoding & Decoding › ROT13 Cipher

ROT13 Cipher

A thirteen-place letter shift that undoes itself — obfuscation, not secrecy.

🔒 Runs in your browser. Nothing is uploaded — verify it in the network panel, or disconnect and try again.

Self-inverse by arithmetic

ROT13 shifts each letter of the alphabet thirteen places, wrapping around. The Latin alphabet has 26 letters, so applying the shift twice returns you to the start: 13 + 13 = 26. That means there is no separate decode function — the same operation both encodes and decodes. Case is preserved, digits and punctuation are untouched, and Hello, World! becomes Uryyb, Jbeyq!.

A short, honest history

ROT13 appeared on Usenet around 1981 for hiding punchlines, spoilers and puzzle answers from a casual glance, and it persists in that role — cryptographic software development has long used it to hide challenge answers in plain sight, and it still shows up as a lightweight way to keep a solution out of a reader's eyeline.

Why it provides no security whatsoever

If you need confidentiality, ROT13 is not a weak option — it is not an option at all. It is an encoding, in the same category as Base64. For real protection, use authenticated encryption such as AES-GCM or XChaCha20-Poly1305, and never invent your own scheme.

ROT-N and the broader family

The general form is a Caesar shift of any amount, and this page's decoder accepts the standard 13 which is the only shift that is its own inverse. Related teaching ciphers — ROT5 and ROT18 for digits, Atbash for reversal — are occasionally used in puzzle chains and CTF exercises, which is precisely the context where their properties are useful rather than misleading.

How to use it

  1. Paste the text.
  2. Read the shifted output — letters move thirteen places, everything else stays.
  3. Paste the output back in to confirm it returns to the original.

Worth knowing

  • 13 is the only shift that is its own inverse in a 26-letter alphabet.
  • Non-letter characters — spaces, digits, punctuation — pass through unchanged.
  • Case is preserved: uppercase stays uppercase and lowercase stays lowercase.
  • Used on Usenet from about 1981 to hide punchlines and puzzle answers.

Limitations

  • No key, so no security — it is reversible by anyone.
  • Works only on the basic Latin alphabet; accented letters and non-Latin scripts are unchanged.
  • It is obfuscation, in the same class as Base64, not encryption.
  • A Caesar cipher of any shift is breakable by brute force alone.

Frequently asked questions

Is ROT13 encryption?
No. There is no key, there is exactly one transformation, and anyone can reverse it. It is an encoding used to hide text from casual reading, nothing more.
Why is there no separate decode?
Because shifting by 13 twice gives 26, a full cycle back to the start. The function is its own inverse, so one operation does both jobs.
Does ROT13 work on numbers?
Not in its standard form. Digits pass through untouched. The variants ROT5 and ROT18 extend the idea to digits and to alphanumerics respectively, and they appear mostly in puzzle contexts.
What should I use instead for real secrecy?
Authenticated encryption — AES-GCM or XChaCha20-Poly1305 with a fresh nonce — using a well-reviewed library. Never a home-built cipher, and never a Caesar shift.
Related tools
Base64 Encoder / DecoderHex Encoder / DecoderHTML Entity Encoder / DecoderURL Encoder / DecoderJWT DecoderQuery String Parser
Keep reading
How browser-only processing worksAll Encoding & Decoding toolsEvery tool on the site