Polybius square cipher
A 5×5 grid turns every letter into two digits. Switch to a key word of your own if you like.
Grid: Numbers 1–5
| 1 | 2 | 3 | 4 | 5 | |
|---|---|---|---|---|---|
| 1 | A | B | C | D | E |
| 2 | F | G | H | I/J | K |
| 3 | L | M | N | O | P |
| 4 | Q | R | S | T | U |
| 5 | V | W | X | Y | Z |
Code = row digit followed by column digit. I and J share one cell, so a code of 24 reads as I/J.
How the Polybius square works
The Polybius square is named after the Greek historian Polybius. A 5×5 grid holds the alphabet, with the rows and columns numbered 1 to 5. Every letter becomes two digits: the number of its row, then the number of its column. HELLO is 23 15 31 31 34.
A grid of 5×5 has 25 cells and the alphabet has 26 letters, so two letters share a cell. In the numeric key, which is the classic square, I and J share one cell; a code of 24 reads as I or J, and you decide from the word.
Instead of numbers you can label the grid with two key words of five different letters, one across the top and one down the left. Then every letter becomes two letters, row first. In that mode the alphabet fills the grid from A to Y and Y and Z share the last cell. The grid in use is always shown next to the result.
Example: HELLO
Find each letter in the grid. Its row number comes first, then its column number:
- H23
- E15
- L31
- L31
- O34
Result: 23 15 31 31 34
Other ciphers
Letters can also become single numbers with A1Z26, or swap with other letters in ROT13 and the Atbash cipher. All of them are on the scout codes page.