Playfair Cypher System

Encrypt or Decrypt text with this Victorian-era 'Substitution Cypher'

The Playfair Cipher is a symmetric encryption technique and was the first literal digraph substitution cipher.
Unlike simpler ciphers that encrypt one letter at a time, Playfair encrypts pairs of letters (digraphs), making it significantly harder to crack using traditional frequency analysis.
Invented in 1854 by Charles Wheatstone, it is named in honour of Lord Playfair, who popularized its use for military purposes.

As with all such cyphers, it is no longer considered secure, particularly for longer messages.
(Show/Hide Information Panel)

Usage:

To use this tool, choose a keyword, and enter it into the first text box. Choose which two letters to combine, from the list between the two text boxes. (The grid only has space for 25 letters)
Click the [Generate Cypher Grid] button. Then either:
Print the grid, and use if offline.
Or: Click/tap each letter of your message, in turn, within the letter grid.
Or: To encrypt in one go, enter/paste the entire message into the lower text box, then click/tap [Encrypt Message Above]
Or: To decrypt, enter/paste the encrypted message into the lower text box, then click/tap [Decrypt Message Above]

Due to the nature of the cypher, decrypted text may contain the letter X as the very last character, and will always show 'extra' X's if the message contains the same letter twice in a row. For example 'HELLO' when encoded and then decoded will show as: 'HELXLO'

Configure The Cypher

Grid:

Text:

Message To Encrypt:

Encrypted Text:

De-crypted Message: