The Digraph Cipher is a classical encryption technique that encodes plaintext two letters at a time — in units called digraphs. By encrypting pairs of letters instead of individual letters, it hides single-letter frequency patterns, making simple frequency analysis ineffective. This is why it is stronger than single-letter substitution ciphers like the Simple Substitution Cipher.
A common approach uses a 5×5 grid (with I and J combined) to assign each letter a coordinate. Each digraph is then encoded by mapping the two letters to their grid positions and combining them according to a predefined rule. This makes it easy to see exactly why a digraph maps to its ciphertext.
Digraph Cipher: Encoding
Consider the plaintext “HELLO.” First, split it into digraphs: HE, LL. Since the number of letters is odd, a filler X is added, making the final digraph L X.
Plaintext Digraphs: HE LL L X
Using the following 5×5 grid (I/J combined):
1 2 3 4 5
A: A B C D E
B: F G H I K
C: L M N O P
D: Q R S T U
E: V W X Y Z
Map each letter to its row and column coordinates. For example:
H → Row B, Column 3
E → Row A, Column 5
→ Combine as BE
L → Row C, Column 1
L → Row C, Column 1
→ Combine as CA
L → Row C, Column 1
X → Row E, Column 3
→ Combine as CC
Writing the ciphertext digraphs sequentially produces:
Ciphertext: BE CA CC
Digraph Cipher: Decoding
Decoding reverses the mapping. Each ciphertext digraph is split back into coordinates and then mapped to the corresponding letters:
Ciphertext: BE CA CC
Mapping back:
BE → H E
CA → L L
CC → L X
Plaintext: HELLOX
Digraph Cipher: Notes
The 5×5 grid makes it clear how each plaintext digraph produces its ciphertext. By working in pairs and using grid coordinates, the Digraph Cipher reduces predictable frequency patterns, providing a more secure classical encryption method. This method forms the foundation for more advanced polygraphic ciphers, like the Bifid Cipher, which further combines coordinates with transposition to increase ciphertext complexity.