Columnar transposition rearranges a message by writing it in rows under a letter key, then reading down the columns in alphabetical key order. If the last row is short, this tool leaves it short. It does not add filler letters.
Set up the grid and key
- The grid uses A–Z letters only. Check the prepared input to see any spaces or punctuation that were removed.
- Use an A–Z key of up to 64 letters. Each key letter gives you one column.
- Read columns in alphabetical key order. Repeated key letters keep their original left-to-right order.
- Read down each column, skipping empty cells at the end.
A repeated-letter key
MEETATNOONKey BALLOON; stable alphabetical order; no paddingEOMOENTNAT| Position | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
|---|---|---|---|---|---|---|---|
| Key | B | A | L | L | O | O | N |
| Row 1 | M | E | E | T | A | T | N |
| Row 2 | O | O | N | — | — | — | — |
| Read rank | 2 | 1 | 3 | 4 | 6 | 7 | 5 |
The columns are read in this order: 2, 1, 3, 4, 7, 5, 6. They contribute EO, MO, EN, T, N, A, T, giving EOMOENTNAT. Notice that the longer columns are the first three in the original grid, even after the key puts them in a different reading order.
Account for the short columns
Ten letters across seven columns make one full row with three letters left over. Original columns 1–3 therefore hold two letters each; the rest hold one. To decode, split the ciphertext using those lengths in key order, put the columns back, and read across the rows.
Try one yourself
Encode ABCDE using key CAB. Do not add a sixth letter.