Atbash Cipher Encoder & Decoder
Type a message to encode it with the Atbash cipher, or paste Atbash text to decode it. The alphabet is folded in half, so A swaps with Z, B with Y and C with X, and the same box works in both directions.
Atbash is its own inverse: running it twice gives the original back, so there is no separate decode step to get wrong. Capitals stay capitals, punctuation and numbers stay as typed, and Hebrew text is enciphered with the original Hebrew Atbash.
The Atbash Key
Every letter and its Atbash partner. Read it in either direction: each pair swaps both ways, so the same key encodes and decodes.
- A becomes Z
- B becomes Y
- C becomes X
- D becomes W
- E becomes V
- F becomes U
- G becomes T
- H becomes S
- I becomes R
- J becomes Q
- K becomes P
- L becomes O
- M becomes N
- N becomes M
- O becomes L
- P becomes K
- Q becomes J
- R becomes I
- S becomes H
- T becomes G
- U becomes F
- V becomes E
- W becomes D
- X becomes C
- Y becomes B
- Z becomes A
The Hebrew Atbash Key
The original Atbash over the 22 Hebrew letters, aleph to tav. Final forms are enciphered as their ordinary letter.
- א becomes ת
- ב becomes ש
- ג becomes ר
- ד becomes ק
- ה becomes צ
- ו becomes פ
- ז becomes ע
- ח becomes ס
- ט becomes נ
- י becomes מ
- כ becomes ל
- ל becomes כ
- מ becomes י
- נ becomes ט
- ס becomes ח
- ע becomes ז
- פ becomes ו
- צ becomes ה
- ק becomes ד
- ר becomes ג
- ש becomes ב
- ת becomes א
Atbash Cipher Examples
Each output below comes from the same code as the tool. Paste any output back in and you get the input again.
| Input | Output | What it shows |
|---|---|---|
| Hello, World! | Svool, Dliow! | H is the 8th letter, so it becomes S, the 8th from the end. |
| Svool, Dliow! | Hello, World! | Decoding is the same operation: the encoded text turns straight back. |
| Meet at the old oak at 9 | Nvvg zg gsv low lzp zg 9 | Numbers and spaces are not part of the cipher and stay as typed. |
| wizard | draziw | Some words become their own reversal: wizard enciphers to draziw. |
| ABCXYZ | ZYXCBA | The two ends of the alphabet swap places, and capitals stay capitals. |
| MN | NM | M and N, the middle pair, swap with each other. No letter stays the same. |
| אבג | תשר | Hebrew Atbash: aleph swaps with tav, bet with shin, gimel with resh. |
How the Atbash Cipher Works
Atbash is a substitution cipher with a fixed key: the alphabet written forwards above the alphabet written backwards.
Each letter swaps with its mirror
The first letter swaps with the last, the second with the second-to-last, and so on: A and Z, B and Y, C and X, through to M and N in the middle.
The same step decodes
Because the swaps are pairs, swapping twice puts every letter back. Encoding and decoding are the same operation, which is why this tool has one mode.
Only letters change
Spaces, punctuation, digits and emoji are not part of the alphabet, so they pass through untouched. Upper and lower case are kept.
Hebrew letters use the Hebrew alphabet
The name Atbash comes from Hebrew: aleph swaps with tav and bet with shin (A-T-B-Sh). Hebrew text is enciphered over its own 22 letters. Final forms such as final mem are enciphered as the ordinary letter, so they come back in their ordinary form.
Atbash, Backwards Text or Pig Latin?
Three easy codes compared on the same message.
Shared input: Secret message
What Atbash Leaves Alone
The cipher is defined for one alphabet at a time, so a few kinds of character fall outside it.
Accented letters
A precomposed letter such as é is not one of the 26 and stays as typed. An accent typed as a separate mark stays on whichever letter its base letter becomes.
Other alphabets
Greek, Cyrillic and other scripts are passed through. Only A to Z and the Hebrew letters are enciphered.
Hebrew final letters
A final letter turns into an ordinary letter, so a word that ends in a final form will not come back in exactly the same spelling after two passes.
It is not secure
Atbash has a single fixed key, so anyone who recognises it can read the message. Use it for puzzles and games, never to protect anything private.
Where the Atbash Cipher Turns Up
Atbash is one of the oldest known ciphers and still one of the most common in puzzles.
The Hebrew Bible
Atbash comes from Hebrew. Scholars commonly read "Sheshach" in the Book of Jeremiah as Atbash for Babel (Babylon).
Puzzle hunts and escape rooms
Because the key never changes, Atbash is a favourite first cipher in puzzle hunts, geocaches and escape-room clues.
Classrooms
It is a simple way to introduce substitution ciphers: students can write the key out in a minute and check their own answers here.
Games and fiction
Hidden messages in games, books and shows are often written in Atbash. Paste a suspicious string to test the idea.
When to Use an Atbash Decoder
Solving a clue
Paste the ciphertext; if it turns into words, it was Atbash.
Writing a puzzle
Encode the answer to a riddle or a treasure-hunt clue.
Checking homework
Encode a sentence by hand, then compare it with the result here.
Learning the key
Use the examples to spot patterns, like M and N swapping in the middle.
Frequently Asked Questions
Paste the encoded text into the box. Atbash undoes itself, so the result is the decoded message. There is no separate decode setting.
A↔Z, B↔Y, C↔X, D↔W, E↔V, F↔U, G↔T, H↔S, I↔R, J↔Q, K↔P, L↔O and M↔N. Write the alphabet forwards, write it backwards underneath, and read straight down.
No. The English alphabet has 26 letters, an even number, so every letter has a different partner. The middle pair, M and N, swap with each other.
No. A Caesar cipher shifts every letter the same distance along the alphabet, and ROT13 is a Caesar shift of 13. Atbash reverses the alphabet instead. Both ROT13 and Atbash happen to undo themselves.
Because it is. The cipher was first used with the Hebrew alphabet, and its name spells out the first swaps: aleph with tav, bet with shin.
No. The cipher runs in your browser and the text is not sent to a server.
Related Text Tools
Binary Translator
Convert text to 8-bit UTF-8 binary code and decode binary back to text.
Morse Code Translator
Translate text to International Morse code, decode dots and dashes, and play audio beeps.
Caesar Cipher Translator
Encode and decode Caesar shift ciphers, ROT13, or scan all 25 shifts at once.
Letters to Numbers Converter
Convert letters to numbers, A=1 to Z=26, and decode A1Z26 number codes back to text.
Pig Latin Translator
Translate English into Pig Latin, with the "way" or "yay" rule for words that start with a vowel.
Enchanting Table Translator
Write English in Minecraft enchanting table letters, and read them back.
Word Scrambler
Scramble the letters of every word, or shuffle the word order of each sentence.
Backwards Text Generator
Turn any sentence into backwards text, character by character.