ROT47, the printable-ASCII Caesar shift
ROT47 is the ASCII generalisation of ROT13. Where ROT13 shifts only the 26 ASCII letters by 13, ROT47 shifts every printable ASCII character (codepoints 33 through 126, the 94 characters from ! through ~) by 47. Because 47 + 47 = 94, applying ROT47 twice returns the original text. So like ROT13, encoding and decoding are the same operation.
Inside the cipher's range, A (codepoint 65) maps to p (codepoint 112), 0 (codepoint 48) maps to _ (codepoint 95), ! (codepoint 33) maps to P (codepoint 80). The implementation is 33 + ((code - 33 + 47) % 94): subtract the base, add the shift, mod 94, add the base back. Letters, digits, and punctuation all participate equally.
Outside the printable ASCII range, characters pass through unchanged. Spaces (codepoint 32) stay as spaces; line breaks, tabs, and any non-ASCII character (accented Latin, Cyrillic, CJK, emoji) are untouched. ROT47 is a classical cipher / Usenet convention and is not encryption: anyone who knows what ROT47 is decodes it in one step. Use it for spoiler hiding, light obfuscation, and as a teaching example. For only-letter ROT, use ROT13.
How to use rot47 cipher
- 1Paste or type your text into the input panel on the left.
- 2The ROT47 result appears in the output panel on the right as you type.
- 3Apply ROT47 again to decode (the cipher is its own inverse).
- 4Click Copy in the output header to copy the result.
- 5Use ROT13 if you only want to shift letters; use Caesar cipher for arbitrary shifts.
Keyboard shortcuts
Drive TextResult without touching the mouse.
| Shortcut | Action |
|---|---|
| Ctrl F | Open the find & replace panel inside the input Plus |
| Ctrl Z | Undo the last input change |
| Ctrl Shift Z | Redo |
| Ctrl Shift Enter | Toggle fullscreen focus on the editor Plus |
| Esc | Close find & replace, or exit fullscreen |
| Ctrl K | Open the command palette to jump to any tool Plus |
| Ctrl S | Save current workflow draft Plus |
| Ctrl P | Run a saved workflow Plus |
What this tool actually does
Shift across all 94 printable ASCII characters
Codepoints 33 through 126 (! through ~) shift forward 47 positions, wrapping. Letters, digits, and ASCII punctuation are all in scope. A -> p, 1 -> `, ! -> P.
Self-inverse: encode and decode are the same
Because 47 + 47 = 94, applying ROT47 twice returns the original. Like ROT13, there is no separate decode button.
Wrap-around at the printable range edges
Past ~ wraps to !; before ! wraps to ~. Implementation: 33 + ((code - 33 + 47) % 94), which preserves the wrap correctly.
Non-printable and non-ASCII pass through
The space character (codepoint 32) is below the cipher range and passes through. Tabs, line breaks, and any character at codepoint 127 or above (accented Latin, Cyrillic, CJK, emoji) are untouched.
Not encryption
ROT47 is reversible by anyone who knows the cipher. Use it for spoiler hiding, Usenet-style light obfuscation, and as a teaching example, not for anything that needs to stay secret.
Worked example
H -> w, e -> 6, the comma -> [, the space passes through, the ! -> P. Apply ROT47 to the output and you get the input back. For letter-only shifts, see ROT13.
Hello, world!
w6==@[ H@C=5P
Settings reference
| Behaviour | Effect on output |
|---|---|
Printable ASCII (codepoints 33-126) |
Shift forward 47 positions through the 94-character range, wrapping. |
| ASCII letters | Shift like everything else. A -> p, z -> K. |
Digits 0-9 |
Shift. 0 -> _, 5 -> d, 9 -> h. |
| ASCII punctuation | Shifts as part of the 94-character range. ! -> P, , -> [. |
| Space character (codepoint 32) | Pass through unchanged (below the cipher range). |
| Tabs, line breaks | Pass through unchanged. |
| Non-ASCII characters | Accented Latin, Cyrillic, CJK, emoji all pass through unchanged. |