Skip to content

Cipher Identifier

Paste a mystery message and the tool measures it — which characters it uses, how the letters are grouped, its index of coincidence, how English its letter pairs look and whether a repeating key length shows up — then ranks the cipher families that fit, with the reasons and a link to a solver for each. It reports how sure it is; it does not pretend to decode. Free, no sign-up.

Paste cipher text, numbers or symbols. Spaces and line breaks are fine. A few hundred letters give far better guesses than a few words. Nothing leaves your browser.

Try a sample:

Most likely, in order

These are guesses from simple measurements, not proof. A strong signal means the evidence fits that family and little else; try the linked tool to confirm.

  1. Repeating-key cipher

    Strong signal

    Several shifted alphabets used in turn, as in the Vigenère, Beaufort and Porta ciphers. The key length is the first thing to find.

    • The index of coincidence is 0.0389, between English (about 0.067) and random letters (about 0.038), as when several alphabets are mixed.
    • Dealing the letters into 5 columns gives columns whose average index of coincidence is 0.0598, near English, as if each column were one shifted alphabet.

    Try: Vigenère Cipher Encoder & Decoder, Beaufort Cipher, Porta Cipher

The measurements

MeasureValueWhat to compare it with
Letters A–Z231
Other characters (without spaces)0
Different letters used26
Index of coincidence0.0389English text is about 0.067; random letters about 0.038; a simple substitution or a transposition keeps the English value.
English letter-pair score0.08Plain English usually scores 0.6 or more; shuffled or enciphered text much less.
Letter-frequency distance from English5.47Under about 0.6 the letters are where English puts them; far above that, they have been replaced.
Best repeating-key lengths10 (index 0.062); 5 (index 0.0598); 7 (index 0.0409)The average index of coincidence when the text is dealt into that many columns; near 0.067 suggests the key length.

How to Use the Cipher Identifier

  1. 1. Paste the text. Spaces, line breaks and capitals are fine. The samples above the results show a Caesar shift, a repeating-key cipher, a substitution and a transposition.
  2. 2. Read the ranking. Each family has a strength — strong signal, possible or weak hint — and the reasons that put it there, such as the index of coincidence or a recurring key length.
  3. 3. Open the solver. Each result links to the tools that work on that family. The Caesar, affine and rail fence tools can try every key; keyed ciphers need a crib or more text.
  4. 4. Check the measurements. The table at the end lists every number the guess rests on, with the values to compare it to.

What the Tool Measures

No single test names a cipher, but a handful of cheap ones narrow the field quickly. The first is the character set. Dots and dashes are Morse, a stream of 0s and 1s in groups of eight is binary, pairs of digits from 1 to 5 are a Polybius square, a run of numbers from about 20 to 110 may be a Nihilist cipher, and a text of only A, D, F, G, V and X is an ADFGVX cipher. When the text is letters, the statistics take over.

MeasurementWhat it tells you
Index of coincidenceThe chance that two letters picked at random match. English gives about 0.067 and random letters about 0.038. Substitution and transposition keep the English value; mixing several alphabets pulls it toward random.
English letter pairsHow many common pairs and triples (TH, HE, ING) the text holds. Plain English scores high; a shifted or shuffled version scores low. The tool tries every Caesar shift, Atbash and the affine keys and reports any that read as English.
Letter-frequency distanceHow far the letter counts are from English. Close means the letters are in place and only their order changed (transposition); far with a high index of coincidence means they were replaced (substitution).
Column index of coincidenceDeal the letters into 2, 3, 4 … columns and average the index of coincidence of each. If one length makes it jump to English levels, that is the length of a repeating key, as in the Vigenère cipher.
Repeated groups (Kasiski)The gaps between repeated three-letter groups tend to be multiples of the key length.
Doubled pairsPlayfair never produces a pair of identical letters, so a long, even-length text with none points to a digraph cipher.

Reading an Example

The Repeating key sample is a 231-letter text. Its index of coincidence is 0.0389, nearly that of random letters, so it is neither a plain substitution nor a transposition, both of which would stay near 0.067. Dealing it into five columns brings the average back up to 0.0598, and ten columns, a multiple of five, gives a similar value. The tool takes the smaller length, 5, and lists the Vigenère, Beaufort and Porta ciphers, which all use a repeating key. That is the step a codebreaker takes before attacking each column as a Caesar shift.

Limits You Should Know

  • Short texts are unreliable. Below about 40 letters the statistics are noise, so every statistical guess is capped at possible. A 200-letter text gives much better evidence than a 20-letter one.
  • Combined ciphers hide. If a message was substituted and then transposed, or enciphered twice, the statistics describe neither step. The tool looks for single, classical ciphers.
  • A flat result is not a verdict. Text that looks random fits autokey, Bifid or Trifid, a rotor machine such as Enigma, a one-time pad and modern encryption alike. Nothing here can tell them apart.
  • The rules are hand-made. This is a set of rules based on standard classical-cryptanalysis tests, tuned on texts of 100–400 letters, not a trained model. It shows no probabilities because the rules cannot back them.

Frequently Asked Questions

How do you identify a cipher?
Start with the characters: letters, digits, symbols or dots and dashes narrow the field at once. For letters, compare the index of coincidence with 0.067 (English) and 0.038 (random), check whether a shift reads as English, and look for a repeating key length. This tool runs those checks and ranks the families.
What is the index of coincidence?
The probability that two letters drawn at random from a text are the same. It is about 0.067 for English and 1 ÷ 26, or 0.038, for uniformly random letters. Because it ignores which letters are which, it is unchanged by simple substitution and transposition, and that is what makes it useful for sorting ciphers.
How do I tell a substitution from a transposition cipher?
Both keep the English index of coincidence. In a transposition the letters are the original ones, so E, T and A are still the most frequent. In a substitution the frequency profile is as lopsided but the common letters are different ones. The letter-frequency distance in the table shows which case you have.
How do you find the key length of a Vigenère cipher?
Try each length n from 2 up. Deal the letters into n columns and average the index of coincidence of the columns. At the true length, or a multiple of it, each column is a single Caesar-shifted alphabet and the average jumps toward 0.067. Repeated three-letter groups spaced by multiples of n (the Kasiski test) support it.
Why does the tool say the text is too short?
With fewer than about 40 letters, letter counts vary too much by chance to separate English from random or a shift from a substitution. The tool still gives its best guess, but marks it no stronger than possible.
Can this tool break or decode my cipher?
It identifies; it does not solve. Where a Caesar shift, Atbash or affine key reads as English it shows the first words of the result, and the linked solver tools do the rest. Keyed ciphers need the key, more text or a guessed word.

Related Tools

More in Codes & Ciphers

See all Codes & Ciphers