Cipher Detective
Paste unknown ciphertext and the Detective will walk you through the evidence — letter frequencies, Index of Coincidence, chi-square analysis, Kasiski examination — and show which cipher families best fit the data.
Prepare a transcription — preserve the evidence
Evidence Workbench adds source revisions, image regions, alternative readings, numerical segmentation and homophonic search. Follow the historical decipherment investigations.
Keep the original symbols, spacing and line breaks before making an analysis copy. This workspace is independent of the live Detective input above. A question mark represents one unreadable symbol; a token can also be marked uncertain or missing. This is a small transcription tool, not OCR.
Groups restart at each space or line break. Excluded symbols end a group too; an incomplete group stays visible. Review and explicitly clear annotations before editing the text or tokenization. A change of width does not resolve an uncertain symbol.
| Position | Token | Status |
|---|
Reading: Bernhard Esslinger, Learning and Experiencing Cryptography with CrypTool and SageMath (2024), Chapter 3 §§3.4–3.5.1. See the CrypTool Transcriber and Solver project for document transcription tools, and the reading companion.
Solve a substitution cipher by hand
First time? Follow a complete beginner lesson with contextual clues before trying your own message here.
Build a partial key from cipher letters to plaintext letters. A dot (·) means unknown. This mode assumes a one-to-one A–Z substitution; homophonic ciphers need different rules. Spaces and punctuation are preserved, and word-pattern matching assumes the supplied word boundaries are real.
Enter a plaintext letter beneath each cipher letter. Lock a mapping to keep it while trying suggestions; unlock it before editing. Changing ciphertext starts a fresh key, and Undo restores the previous text, key and locks.
Frequency suggestions fill empty, unlocked entries without displacing your assignments. They are guesses, not a solution. The separate Auto-Solve panel does not modify this desk or use its constraints.
A result is compatible only with this dictionary and your current key hypotheses. Even a sole candidate is not proof of the original message. No word boundaries are invented for continuous text. Pattern matching requires resolved A–Z words separated by whitespace; unknown symbols and punctuation must not be silently treated as boundaries. To keep the search responsive, use at most eight distinct cipherwords, each no longer than 20 letters.
Reading: Al Sweigart, Cracking Codes with Python (2018), Chapter 17: word patterns and intersecting mappings. This small original fixture teaches the constraint step, not the full book’s dictionary attack. Continue the reading trail.
Evidence
Suspects
Case Notes
Recommended Next Attack
🔒 Auto-Solve (Advanced)
Run every applicable solver against this ciphertext and rank the results by how English-like each candidate plaintext is. Works on Caesar, ROT13, Atbash, Vigenère, monoalphabetic substitution and columnar transposition. May take a few seconds for substitution.
For controlled columnar experiments, open the seeded advanced columnar search: set a width and work budget, then compare segment moves, staged scoring and restarts.
Every output is an unverified candidate. The embedded English model supplies a ranking score, not a probability of English or of successful decryption. Inspect the score components before treating a readable result as evidence.
Reading on language-score limits
George Lasry, A Methodology for the Cryptanalysis of Classical Ciphers with Search Metaheuristics (2018 published thesis), §§3.2.3–3.2.4, printed pp. 29–34 / PDF pp. 50–55; Al Sweigart, Cracking Codes with Python: An Introduction to Building and Breaking Ciphers (2018 edition), chapter 11, “How Can a Computer Understand English?” and “Detecting English Words,” supplied reflowed PDF pp. 183–184 and 199–202 (original printed folios unverified). These passages explain limits of word and statistical scoring; they do not calibrate this model.
What the Detective can’t tell you
- Short ciphertext can make statistical analysis unreliable; the roughly 60-character warning is a teaching heuristic, not a universal threshold.
- English-language scores can mislead on non-English plaintext.
- Random-looking data may be encrypted, compressed or simply random. These letter-based heuristics cannot reliably identify a modern cipher, establish its security or prove that a sample is encrypted.
- Layered constructions and simplified machine models can confound single-pass identification.
- The Detective’s Auto-Solve can recover plaintext for Caesar, ROT13, Atbash, Vigenère, monoalphabetic substitution, and columnar transposition. For richer hand-tools and other ciphers, open the Codebreaker’s Workbench.