How to Encode Text with ROT13

ROT13 is the simplest cipher there is: shift every letter 13 places through the alphabet, and encoding and decoding become the same operation. It takes one click, it needs no key, and it is perfect for hiding a spoiler or a puzzle answer — just never for keeping a real secret.

What ROT13 is

Each letter shifts 13 places

ROT13 is a letter substitution cipher: each letter is replaced by the letter 13 places further along the alphabet. A becomes N, B becomes O, N becomes A again. Because the alphabet has 26 letters, shifting by 13 twice brings you back to the start, which makes encoding and decoding the same operation. There is no key to remember and no separate decode step — the same button does both jobs.

A 1980s forum trick for spoilers

It is one of the oldest tricks in computing. ROT13 appeared on early internet forums in the 1980s as a way to hide punchlines, puzzle solutions and spoilers: a reader who wanted to see the answer could decode it, while everyone else saw only scrambled text. It was never meant to keep secrets — it was a courtesy, a way of saying this part is optional.

Why ROT13 is not encryption

No security at all

It is important to be honest about what ROT13 is not: it is not encryption, and it provides no security at all. Anyone who recognises the pattern can decode it in their head, and every ROT13 decoder on the internet will do it in one click. A message encoded with ROT13 is as readable as a message in plain text to anyone who tries for even a second.

A puzzle, not a lock

That does not make it useless — it makes it a puzzle, a joke and a spoiler shield, not a lock. Never use ROT13 for passwords, private messages or anything that must stay secret. For real privacy you need real encryption, and for hiding a spoiler from a casual glance, ROT13 is exactly the right amount of effort.

Encode text with ROT13 in four steps

  1. Write or paste your text. Type the message, spoiler or puzzle answer you want to encode — or paste ROT13 text you want to decode.
  2. Open the tool. Go to the ROT13 Encoder and Decoder. It runs entirely in your browser, so nothing you paste is uploaded anywhere.
  3. Click Apply ROT13. Every letter shifts 13 places. Numbers, spaces and punctuation pass through untouched, so the shape of the message stays recognisable.
  4. Copy the result. Share the encoded text, or run the same operation on it to decode it back to the original.

Where ROT13 still shows up

ROT13 survives in places where obscurity, not secrecy, is the goal. Puzzle hunts and escape rooms use it as a first-step cipher. Email addresses are sometimes ROT13-encoded to slow down the simplest harvesting bots, though that barely works today. Forums still use it for spoilers, and programmers use it as a classic first exercise when learning string manipulation, because it is simple enough to write in a few lines and satisfying to get right.

It also has a neat mathematical property: because 13 is exactly half of 26, ROT13 is its own inverse, which is rare among ciphers. Shift by any other number and you need a different operation to decode. Shift by 13 and one function does everything — which is why the tool has a single button.

ROT13 as a first step into ciphers

ROT13 is a gentle introduction to how ciphers work in general. Every substitution cipher replaces letters by a rule, and ROT13 is the simplest rule there is: add 13, wrap around at Z. Once you understand that, the Caesar cipher is the same idea with a different shift, and the Vigenere cipher is the same idea with a shifting shift.

Programmers still write ROT13 as a first exercise because it teaches string handling, modular arithmetic and character codes in a single short function — and because the result is immediately satisfying to test. Try encoding a sentence by hand first, then check it against the tool.

Related guides

Questions people ask

How do I decode ROT13 text?

Run the same operation again. ROT13 is its own inverse: shifting by 13 twice returns every letter to its original place, so the same button encodes and decodes.

Does ROT13 change numbers and punctuation?

No. Only the 26 letters of the English alphabet are shifted. Numbers, spaces, punctuation and letters from other alphabets pass through unchanged.

Is ROT13 secure?

No. ROT13 provides no security at all and anyone can decode it instantly. It is a puzzle and a spoiler shield, not encryption. Never use it for anything private.

Why 13 and not another number?

Because 13 is half of 26, shifting twice returns to the start. That makes ROT13 its own inverse, so one operation both encodes and decodes.