ToolPuma Logo

Playfair Cipher

Encrypt or decrypt text with the Playfair digraph cipher.

Note: The Playfair cipher encrypts pairs of letters (digraphs) using a 5x5 square built from a keyword. It merges I and J, inserts an X filler for repeated or trailing letters, and is not secure for modern use.

What Is a Playfair Cipher?

The Playfair Cipher tool encrypts and decrypts text using a 5x5 digraph (pair-of-letters) substitution built from a keyword. It was the first practical digraph cipher and was used by the British in World War I. This free online tool is useful for Playfair cipher, Playfair cipher online, Playfair encrypt decrypt. Common use cases include classical cryptography, historical ciphers, puzzles, and cryptography education. It is designed for quick browser-based hashing, encoding, decoding, encryption testing, checksum comparison, identifier generation, and cryptography education. For production security, follow the algorithm's current standards, key-management requirements, and application-specific security guidance.

How to Use This Playfair Cipher

  1. 1
    Choose the directionSelect Encrypt or Decrypt where the tool provides both operations.
  2. 2
    Enter the settingsProvide the shift, keyword, rails, or other cipher parameters.
  3. 3
    Enter the textPaste the plaintext or ciphertext into the input field.
  4. 4
    Run the transformationThe tool applies the selected classical cipher locally.
  5. 5
    Review the resultCopy the transformed text for your puzzle, experiment, or educational exercise.

Frequently Asked Questions

The keyword fills the square first, then the remaining alphabet letters. Because there are 26 letters but only 25 cells, I and J share a cell. Pairs are encrypted by shifting along rows, columns, or rectangle corners.
Repeated letters in a pair (like 'LL') and an odd final letter get an 'X' inserted so every pair is distinct, which the cipher requires.