Using the Polybius tool
Type on the left, read coordinates on the right. Between pairs sets what separates them, and the tightest setting runs the digits together, which is how the square usually appears inside larger ciphers.
Paste digits in and swap the boxes to read them back. Anything that isn't a digit from 1 to 5 is ignored on the way back, so a message copied out of a puzzle with stray punctuation still decodes.
How the grid works
Twenty-five cells hold the alphabet in order, five to a row. H sits in row 2, column 3, so it becomes 23. The digits never go above 5, and that ceiling is the giveaway when you meet the square in the wild.
I and J share cell 24. Encoding a J gives 24, and decoding 24 always gives back I, so a name like Jim comes back as Iim. Readers are expected to fix it. The tap code makes the opposite trade and drops K instead.
The square, cell by cell
Torches on a hillside
Polybius was a Greek historian writing in the 2nd century BC, and he set the square out in Book 10 of his Histories. He wasn't describing a cipher. He was solving a signalling problem.
Armies could already signal with fire, but only messages agreed in advance. A torch meant the enemy is coming, and nothing else could be said. Polybius credits Cleoxenus and Democleitus with the idea of splitting the alphabet into five groups, then describes his own refinement: hold up torches on the left for the row and torches on the right for the column.
That gives you a general-purpose alphabet over a distance you can see, roughly two thousand years before the electric telegraph. The cipher use came much later. Its real career was as a component, feeding the Nihilist cipher, the ADFGVX cipher the German army used in 1918, and the knocks on a prison wall.
Related conversions
Tap code is this square turned into sound, with the row and column counted out rather than written down. Playfair builds the same 5x5 grid from a key phrase, then uses it to swap corners instead of reading coordinates.
For a simpler letters-to-numbers scheme with no grid at all, A1Z26 just counts along the alphabet.
Questions
What is a Polybius square?
A 5x5 grid holding the alphabet, used to turn each letter into a pair of digits for its row and column. I and J share a cell so that 26 letters fit in 25.
Why are there no digits above 5?
The grid is five cells wide and five deep, so every coordinate falls between 1 and 5. A string of digits with no 6 through 9 in it is often a Polybius square.
Can numbers be encoded?
Not by the square itself. It holds letters only. Messages that need digits usually spell them out or switch to a 6x6 grid that carries 0 to 9 as well.
Where is the Polybius square still used?
Mostly inside other ciphers. The Nihilist cipher adds a key to the coordinates, and ADFGVX relabels the rows and columns with six letters chosen to be distinct in Morse.



