Baconian Cipher
Encode and decode messages with the Baconian cipher.
Result
How it is calculated
The Baconian cipher replaces each letter with a group of five symbols, a or b. In this 26-letter version the letter's position in the alphabet counted from 0 (A = 0, B = 1 … Z = 25) is written as a 5-bit binary number, with 0 as a and 1 as b. So A = aaaaa, B = aaaab and Z = bbaab.
When encoding, the text is made uppercase, letters within a word are separated by one space and words by two spaces; digits, punctuation and accented letters are skipped. When decoding, only a and b (any case) are read, everything else is ignored, and the symbols are cut into groups of five from the start. A group whose value is above 25 is dropped, and a leftover group shorter than five is ignored. The original I/J and U/V merged variant is not used.
Worked example
Encode Hello. H is letter number 7, which is 00111 in binary, so aabbb. E is 4, 00100, so aabaa. L is 11, 01011, so ababb, and it appears twice. O is 14, 01110, so abbba. Joined with spaces the result is aabbb aabaa ababb ababb abbba.
Common mistakes
- Counting the alphabet from 1 instead of 0. A must be
aaaaa, notaaaab, or every letter shifts by one. - Decoding text that uses the historic 24-letter table, where I/J and U/V share a code. Those messages will decode with some wrong letters here.
- Breaking the a/b string into groups of the wrong size or dropping one symbol; every later letter is then misread.
- Expecting digits or punctuation to be encoded. They are skipped, so they vanish from the message.
About this calculator
This tool encrypts or decrypts text with the Baconian cipher, devised by Sir Francis Bacon, which represents each letter as a unique 5-character sequence of "a" and "b" (essentially a 5-bit binary code, e.g. A = aaaaa, B = aaaab). Its original power was as a steganographic device: the a/b sequence could be hidden in an innocuous cover text using two subtly different typefaces or formats, so the message stayed invisible unless you knew to look.
Cryptography students and puzzle designers use it today to explore early binary encoding and steganography, and to hide messages inside seemingly ordinary text. The tool works in both directions, turning text into a/b groups and a/b or two-symbol sequences back into letters.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments (1)
This tool uses the 26-letter version, where every letter has its own five-symbol a/b code. Older sources use a 24-letter table that merges I with J and U with V, and decoding such a message here may come out wrong from the letter J onward. Digits, punctuation and non-English letters like ş are skipped when encoding. When decoding, only a and b count and they are read in groups of five. Have a puzzle that fails? Paste it.