Text Similarity & Edit Distance
Score how alike two pieces of text are with Levenshtein or Damerau-Levenshtein edit distance, or the Jaro-Winkler similarity used for record matching. Paste a list and every line is scored against a reference line, sorted so the closest matches surface first.
🔒 100% Client-Side & Private — processed locally in your browser. Files never leave your device.
Options
Your result will appear here
Type or paste your input above, adjust the options, then press Run. Tip: press Ctrl+Enter to run, and ? for every shortcut.
How it works
Scoring lines against a reference
Paste any number of lines and each one is compared to a reference, which defaults to the first line unless you fill in the reference field. Every row reports the edit distance, a similarity percentage, and how many characters the start and end share. Choosing lines instead of table output gives compact score d= distance rows.
Picking the right metric
Levenshtein counts insertions, deletions and substitutions. Damerau-Levenshtein also treats one adjacent swap as a single edit, so teh and the stay close together. Jaro-Winkler returns a score from 0 to 1 that rewards a shared opening, which suits matching personal names and records.
Options that change the ranking
Case sensitive is off by default and trim whitespace removes blank lines before comparison. Sort results orders either closest first or in the original input order, and max rows caps the table at 200 lines by default, adjustable up to 5000.
Size ceilings and code points
Input is limited to 200000 characters and 5000 lines. The distance metrics fill a quadratic table, so long pairs are refused once the longer string approaches 2000 characters. Text is compared by code point, so an emoji counts as one unit rather than two.
Comparison stays in the browser
Everything runs on the text you type, locally. No line is uploaded, no request leaves the page, and the tool keeps working offline.
Questions
What is edit distance?
The number of single-character insertions, deletions or substitutions needed to turn one string into the other. A distance of 0 means the strings are identical.
Which metric should I use?
Levenshtein for typos, Damerau-Levenshtein when a swapped pair such as "teh" versus "the" should count as one edit instead of two, and Jaro-Winkler when matching names or records where a shared prefix is a strong signal.
How is the similarity percentage calculated?
For the two distance metrics it is 1 minus distance divided by the length of the longer string, as a percentage. Jaro-Winkler produces its own score between 0 and 1, so no separate distance is shown.
Does it count emoji as one character?
Yes. Text is compared code point by code point, so an astral character such as an emoji counts as a single unit rather than two UTF-16 code units.
Related tools
See categoryText Diff
Compare two blocks of text and see the differences as a unified diff or an inline word/character diff.
Duplicate Line Finder
Find repeated lines in a list, with occurrence counts and first line numbers.
Text Statistics
Count characters, words, sentences and paragraphs, with platform limits, readability scores and reading time.
Character Frequency
Count how often each character occurs, with scope filters, optional case folding and count or character sorting.