← All Tools

Trifid Cipher

Also invented by Felix Delastelle around 1902, the Trifid cipher takes his Bifid idea into three dimensions: 27 alphabet cells (A–Z plus one padding symbol) are arranged into a 3×3×3 cube. Every plaintext letter becomes a triple of trits (layer, row, column, each 1–3); the trits are read down within a block of period length, concatenated, and re-grouped into new triples to produce the ciphertext. Because each letter is split three ways, Trifid diffuses plaintext structure more aggressively than Bifid.

symbols 0 blocks 0 period 0 alphabet size 0/27

3×3×3 Key Cube

Each cell has coordinates (layer, row, column) from 1 to 3. Change the keyword above to rearrange the cube.

Fractionation Breakdown

For the current plaintext, split into blocks of the chosen period. Each column of trits (layer / row / column) is written down, then the rows are concatenated left-to-right and re-grouped three at a time to produce ciphertext letters.

Notes

Alphabet. 26 English letters need 27 cells, so a pad character (traditionally + or .) fills the last slot. Change it above — anything not in the cube is dropped from the plaintext.

Period. Small periods leak too much structure; larger periods diffuse better but leave a partial trailing block. Delastelle originally recommended 5–7 for short messages.

Symmetry. Encryption and decryption are inverse operations of the same algorithm — the only difference is how the trits are re-grouped inside each block.