What Is ROT13? Caesar Cipher Explained
ROT13 ('rotate by 13') is a simple letter substitution cipher that replaces each letter with the letter 13 positions after it in the alphabet. Since the alphabet has 26 letters, applying ROT13 twice returns the original text — making ROT13 its own inverse. It is not used for security; it is used to obscure text from casual reading.
How ROT13 Works
Each letter shifts by 13: A↔N, B↔O, C↔P, ..., M↔Z. Only letters are transformed; numbers, punctuation, and spaces are unchanged. Example: 'Hello, World!' → 'Uryyb, Jbeyq!' Case is preserved. Since 13 + 13 = 26 = alphabet length, encoding and decoding are the same operation.
ROT13 on Usenet and Forums
ROT13 was widely used on 1980s–2000s Usenet newsgroups to hide spoilers, punchlines to jokes, and offensive content behind a thin layer of obscurity. Readers who actively wanted to see the hidden content would decode it; casual readers would skip it. Many early Unix systems included a rot13-encoder-decoder command-line utility.
ROT13 vs ROT47
ROT47 extends ROT13 to cover all 94 printable ASCII characters (codes 33–126), not just letters. It shifts each character by 47 positions in ASCII. Like ROT13, applying ROT47 twice returns the original. ROT47 obfuscates numbers, punctuation, and symbols in addition to letters.
ROT13 for Security?
No. ROT13 provides zero security — any attacker who knows you used ROT13 (which is trivially detectable from text patterns) can instantly decode it. It is a substitution cipher with a fixed, known key. For actual security, use AES-256-GCM for symmetric encryption or RSA/ECC for asymmetric.