We use cookies.This website uses essential cookies to operate core features. With your consent, we also use analytics cookies to understand traffic and improve the service. For more details, see our .
Was this tool helpful to use?
Your feedback helps us make it better
Calculate the Index of Coincidence (IC) for cryptanalysis and language identification with English letter frequency statistics.
Please enter text with at least 2 letters to calculate the Index of Coincidence.
The Index of Coincidence (IC) is a statistical measure used to quantify the uniformity of letter distribution in a text. It is particularly useful in cryptanalysis to help determine if a text is encrypted and what encryption method might have been used.
An IC value close to 0.0667 suggests the text is likely a natural language (e.g., English); an IC value close to 0.0385 suggests the text is random or well-encrypted. Normalized IC multiplies the result by 26 (the number of English letters) to make it easier to interpret.
Overview
Understand what the tool solves, how it works, and the boundaries of its data.
The Index of Coincidence (IC) summarizes how often two letters selected from a text, without replacement, would match. This calculator first removes every character except English A–Z letters, converts remaining letters to uppercase, and reports the effective letter count N. Spaces, punctuation, digits, and non-Latin characters do not affect the result.
IC = Σ fi(fi − 1) / [N(N − 1)]
fᵢ is the count of each A–Z letter and N is the total retained letters. The normalized result is IC × 26.
The page displays raw IC to five decimal places and normalized IC to three. It also shows the retained letter count. For fewer than two retained letters, no statistic is displayed. The statistic is a clue about frequency distribution used in classical cryptanalysis; by itself it does not identify a cipher or recover plaintext.
Guide
Follow the workflow and verify inputs and outputs with practical examples.
Use a sample with enough A–Z letters to make its frequency distribution informative. The filter ignores spaces, punctuation, digits, and other alphabets.
Confirm the displayed text length reflects only retained letters. If the count is zero or one, add more letter data before interpreting a statistic.
Raw IC is the observed matching-pair probability. Normalized IC multiplies that value by 26 for an English-alphabet scale; it is not a percentage or a direct cipher classification.
Compare frequency patterns and test hypotheses separately. Do not infer a plaintext or cipher family from this one number alone.
For an illustrative short string AABC, the counts are A=2, B=1, C=1, N=4. The numerator is 2×1 = 2 and the denominator is 4×3 = 12, so raw IC is 0.16667 and normalized IC is about 4.333. A short sample makes this value unstable, which is why context and length matter.
Use cases
See how the tool fits into real work and everyday tasks.
Calculate the frequency concentration of a ciphertext after confirming that its alphabet is represented by A–Z. Treat the output as one descriptive statistic in a larger analysis.
Use short classroom examples to show how repeated letters contribute to matching pairs, then compare with a larger sample to see how length changes stability.
Apply the same A–Z filtering rule to each excerpt and compare their raw or normalized values. Keep sample lengths and source context in view.
Q&A
Find concise answers to common questions and confusing cases.
Raw IC is the matching-pair probability. The normalized value is raw IC multiplied by 26, a scaling convention for a 26-letter alphabet.
Only A–Z letters are retained. Spaces, numbers, punctuation, and non-Latin letters are excluded before counting.
No. Different texts and methods can produce overlapping values. IC can inform a cryptanalysis hypothesis, but it does not uniquely identify a cipher or decrypt a message.
The formula counts pairs without replacement and divides by N(N−1), which is not defined for fewer than two retained letters. Very short samples also produce volatile estimates.
Notes
Review scope, result limitations, and important precautions before use.
Index of Coincidence is a descriptive statistic, not a decryption result, security test, or definitive language identifier. Interpret it with sample size, alphabet, and other cryptanalytic evidence.
Related
Discover related tools, collections, and available API capabilities.