Columnar transposition cipher
Encrypt or decrypt text by writing it into a grid and reading the columns back in key order.
Columnar transposition cipher
A columnar transposition cipher scrambles a message by writing it row by row into a grid as wide as a chosen key, then reading the grid back column by column in the order the key's letters would sort alphabetically. Nothing is substituted — every letter is still there, just rearranged — which makes it a natural companion to a substitution cipher like Vigenère or Atbash, and the basis of a puzzle-hunt clue where a keyword unlocks the grid.
The key sets two things at once: its length is the number of columns, and the alphabetical order of its letters is the reading order for those columns. Double transposition runs the grid a second time with a second key, resisting the column-frequency analysis a single pass leaves it open to. When the text doesn't divide evenly into full rows, leave the last row short (irregular) or pad it to a full rectangle with a fill character — padding is simpler, but the decrypted text carries that filler at the end. Keep spaces and punctuation for a readable grid, or strip everything but letters and digits for the classic wartime look. Show grid prints the grid as text, so you can see how the key reordered the columns.
The tool works on Unicode code points, so accented letters and emoji survive a round trip, and Windows and Unix line endings are treated the same way. The live tally reports characters in and out, the column count per pass, and whether the result was encrypted or decrypted.
Everything runs in your browser — the text and key you type are never uploaded. Copy the result, download it as a .txt file, or send the output back to the input to decrypt it again or chain another cipher on top.