Bacon Cipher Converter

Encode letters as groups of five A and B symbols with the Baconian cipher.

Technology and NetUpdated 2026-11-192 min read
Bacon Cipher Converter
For encryption, 1 to 100 letters. For decryption, a multiple of five A and B symbols.
Converted message
...
Letters involved...
Operation...

What it does

Bacon's cipher, also called the Baconian or biliteral cipher, encodes each letter as a group of five symbols drawn from two distinct classes, conventionally written A and B. Francis Bacon devised it in the early seventeenth century as a form of steganography.

This tool uses the common twenty four letter alphabet, where I and J share a code and U and V share a code. Encryption converts each letter to its five bit index with A standing for 0 and B for 1. Decryption reads groups of five back into letters.

The page opens with the word BACON. Its codes are AAAAB, AAAAA, AAABA, ABBAB and ABBAA, which concatenate into a continuous A and B string.

Historically the two classes could be represented by two typefaces, shapes or other visual differences hidden in an innocent looking text. The tool works directly with the A and B symbols rather than a cover text.

Because I and J and also U and V share codes, the decoded message needs context to choose the intended letter.

How to use

  1. Type a message of letters for encryption.
  2. Choose encrypt or decrypt.
  3. Read the A and B string as the main result.
  4. For decryption, enter groups of exactly five A and B symbols.
  5. Check the letter count to confirm the conversion.
  6. Use context to decide between I and J or U and V after decryption.

Formula

Each letter index from 0 to 23 is written in five bit binary, then 0 becomes A and 1 becomes B
letter index
Position in the twenty four letter Baconian alphabet.
five bit binary
The index written with five binary digits.
A/B pattern
The binary digits with 0 replaced by A and 1 by B.

The place values of the five positions are 16, 8, 4, 2 and 1. The twenty four letter convention stops at index 23, so the patterns for indices 24 to 31 are unused.

Worked example

Example: BACON

The page opens with the word BACON in encrypt mode.

  1. B has index 1, which is 00001 in five bits, giving AAAAB.
  2. A has index 0, giving AAAAA.
  3. C has index 2, giving AAABA.
  4. O has index 14, giving ABBAB.
  5. N has index 12, giving ABBAA.
  6. The tool reports the concatenated result AAAABAAAAAAAABAABBABABBAA.

Reference table

Baconian codes for sample letters
LetterIndexFive bit binaryA/B pattern
A000000AAAAA
B100001AAAAB
C200010AAABA

Limits

  • Encryption accepts at most 100 letters.
  • Decryption requires a length that is a multiple of five.
  • Uses the twenty four letter alphabet with shared I/J and U/V.
  • The classic two typeface steganography is not modelled.

Common mistakes

  • Using the twenty six letter variant codes by mistake.
  • Splitting the A/B stream into groups other than five.
  • Expecting the tool to decide between I and J.
  • Entering lowercase b instead of B in cipher mode.
  • Assuming the cipher conceals the existence of a message on its own.

Try it yourself

Quick checks. Answers sit tucked under each question.

What is the Baconian code for A?

AAAAA, index zero.

Which letters share a code?

I and J share ABAAA, and U and V share BAABB.

How long is the code for one letter?

Five A or B symbols.

Questions

What is Bacon's cipher?

A method of encoding each letter as five symbols from two classes.

Why five symbols?

Five binary digits provide enough patterns for the alphabet.

Is it a substitution or steganography?

Both. The A/B patterns substitute for letters and can be hidden in two typefaces.

How do I decode?

Split into groups of five, convert A to 0 and B to 1, then map the index to a letter.

What about J and V?

They share codes with I and U in the common variant.

Is it secure?

No. The pattern is regular and easy to recognise.

Sources

How this page was checked. The formula above was matched against the cited sources, and the worked example was run through the tool on this page before publishing. If you spot an error, contact us so we can fix it and note the correction.