Atbash Cipher
Type on the left and the atbash falls out on the right: every letter swapped for its mirror in the alphabet, with upper and lower case kept exactly where you put them. There is one pass rather than an encode and a decode, because a mirror is its own inverse: run the tool on its own output and your text comes back, which the readout checks on whatever is in the box instead of asserting it. Digits, punctuation, accented letters, other scripts and emoji sit outside the alphabet, so they are carried through untouched. The full substitution table is under the stage with the pairs your text uses marked, and a Hebrew mode maps the 22 letters from aleph to tav, the alphabet atbash was named after.
- Alphabet
- Case
- Preserved
- Other characters
- 9 passed through
- Applied twice
- Original back
35 letters mirrored, 9 characters passed through. Running the tool on this result returns your text exactly.
A becomes Z, B becomes Y, M becomes N, and so on to the end of the alphabet. The same pass undoes it. Digits, punctuation, spaces, accented letters, other scripts and emoji are not in this alphabet, so they come out exactly as they went in.
The full substitution table
Every letter of Latin A-Z, and what it becomes. The pairs your text uses are marked, and reading the table upwards gives the same answer, because the mapping is a mirror rather than a shift.
| Plain | A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Atbash | Z | Y | X | W | V | U | T | S | R | Q | P | O | N | M | L | K | J | I | H | G | F | E | D | C | B | A |
Common questions
- How does the atbash cipher work?
- Write the alphabet out forwards, write it out backwards underneath, and swap each letter for the one below it. A becomes Z, B becomes Y, M becomes N, and so on to the end. It is a reflection rather than a shift, so there is no key to choose and no number of places to set. ABCxyz becomes ZYXcba, and the table on the page shows every pair at once.
- How do I decode an atbash message?
- Paste the coded text into the same box and read the answer on the right. There is no separate decode button, because there would be nothing for it to do differently: atbash is its own inverse, so one pass covers both directions. The Applied twice cell in the readout checks that on whatever you have pasted, and the status line under it says how many letters were mirrored and how many characters passed through.
- What happens to numbers, punctuation, spaces and emoji?
- They come out exactly as they went in. Only the letters of the alphabet you picked are mapped, so digits, spaces, punctuation, accented letters such as é, Greek, Cyrillic, Chinese, Japanese and emoji are carried through in place, including emoji built from more than one code point. Hello, World! becomes Svool, Dliow!, with the comma, the space and the exclamation mark where they were.
- Does this do the Hebrew atbash?
- Yes, and that is the original: the name is itself the cipher, aleph tav bet shin, the first letter paired with the last and the second with the second last. Switch the Alphabet cell to Hebrew and the 22 letters from aleph to tav are mapped, so aleph becomes tav and bet becomes shin. The five final forms, the shapes kaf, mem, nun, pe and tsadi take at the end of a word, are not among those letters and pass through unchanged. That is deliberate: their partners have no final form, so mapping them would break the promise that a second pass returns exactly what you typed.
- Is the atbash cipher secure?
- No, and it never was. Atbash has one fixed key that everybody already knows, so anyone who recognises the cipher can read the message with the table on this page, or with a pencil and two lines of alphabet. Treat it as a puzzle cipher: escape rooms, geocaching, crosswords, homework and old texts. Anything that genuinely has to stay private needs modern encryption.
- How is atbash different from ROT13?
- ROT13 shifts every letter thirteen places along the alphabet, so A and N trade places. Atbash reflects the alphabet instead, so A and Z trade places, and the pairs get closer together as you move towards the middle until M and N sit side by side. Both are their own inverse, which is why each needs only one pass, and the two produce different text: ABCxyz is ZYXcba here.
- Where does the atbash cipher come from?
- It is Hebrew, and it is old. Scribes used it as a substitution over the 22 letters, and the Book of Jeremiah carries it: the name Babel, written bet bet lamed, appears with each letter mirrored, which this tool renders as shin shin kaf. The received text writes that last letter in its end-of-word form, because it ends the word, and this tool leaves final forms alone, so the two differ in the shape of one letter and not in which letters they are.
- Is what I type sent anywhere?
- No. The mirror, the table and the round-trip check all run in your own browser, and nothing you type leaves the page. Your text and the alphabet you chose are kept in this browser so the tool comes back as you left it. The example the page opens with is never saved, emptying the box while Latin is selected removes the record, and Start over, in the row above the heading, removes it and reloads the page.
Exact substitution: each letter maps to its mirror in the chosen alphabet, and the full table is on the page so you can check any letter by eye. Case is kept, anything outside the alphabet is passed through, and applying it a second time returns the original exactly. Atbash has one fixed, public key: it is a puzzle cipher for reading and teaching, and it keeps nothing secret.