Skip to content
ToolsOnDuty - free online tools

Search tools

Loading tool search...

Writing

Text Similarity vs Meaning: How to Read an Edit-Distance Score

Interpret edit distance with verified examples, understand why negation can score highly and avoid treating similarity as meaning.

By ToolsOnDuty Editorial Team

Text Similarity Calculator returning distance 3 and similarity 57.14 for kitten and sitting

Similar-looking text does not necessarily mean the same thing. A character-based percentage is useful only when you know what it measures and inspect the changes that produced it.

This guide completes an earlier unpublished draft with two verified browser comparisons and real screenshots. The examples use synthetic text, not personal records or private documents.

Start with the decision, not the percentage

A comparison score can help you spot similar spellings. It cannot tell you whether two instructions, names or statements are interchangeable. An added not can reverse a decision while leaving most letters unchanged.

Use the Text Similarity Calculator to answer a narrow question about character sequences. Keep the actual wording beside the number. The tool is not a plagiarism detector, semantic-equivalence test, factual checker or authorization decision.

What the calculator measures

The tool uses Levenshtein distance: the minimum number of single-character insertions, deletions and substitutions needed to transform one input into the other. Each operation costs one. It divides that edit count by the longer input's length and turns the result into a percentage.

Length is measured in Unicode code points, not words. A code point is not always a whole visible character. The percentage is rounded to two decimal places; precision in the displayed number does not add knowledge about the importance of the edits.

text
similarity = 100 x (1 - edit distance / longer input length)

Reproduce a spelling comparison

Enter kitten in First text and sitting in Second text, then select Compare text. The observed result is distance 3 and similarity 57.14. One valid edit sequence replaces k with s, replaces e with i and appends g.

The longer input has seven code points, so the calculation is 100 x (1 - 3/7). This is a transparent spelling comparison, not a claim that the words share 57.14 percent of their meaning. Both the edit count and the underlying strings matter.

Text Similarity Calculator returning distance 3 and similarity 57.14 for kitten and sitting
Actual browser comparison with short synthetic text.
json
{
  "distance": 3,
  "similarity": 57.14
}

A higher score can hide a more important change

Replace the inputs with approved and not approved. The observed result is distance 4 and similarity 66.67. The longer input has twelve code points, and the added word plus its space accounts for four insertions.

The percentage is higher than the kitten/sitting example even though the added negation reverses the approval. The calculator has not necessarily failed. It is accurately answering a smaller question than whether the statements have the same operational meaning.

An approval and its negation producing a 66.67 similarity score
Shared characters raise the score; the added not changes the decision.
json
{
  "distance": 4,
  "similarity": 66.67
}

Equal percentages do not identify equal risks

Cat and cut differ by one substitution across three code points, so their score is also 66.67. That equal percentage describes a different edit from adding not to approved. A percentage has no universal interpretation independent of its inputs.

A one-character change in an invoice reference might identify a different payment. A larger spelling change might still refer to the same idea. The metric assigns unit edit costs, not business importance. Check relevant source information rather than inventing a universal merge threshold.

Understand trimming, case and Unicode

The page requires non-empty inputs and trims outer whitespace before comparison. Internal spaces and letter case remain part of the input. Each trimmed value is limited to 2,000 Unicode code points, so use a focused passage instead of assuming a complete document fits.

The similarity calculation does not normalize equivalent-looking Unicode sequences. A precomposed accented letter and a letter followed by a combining mark can occupy different code-point sequences. A visually close result can therefore need a separate normalization decision; changing normalization can also change what you are trying to preserve.

Choose the comparison that supports the review

Use Text Similarity for a short, explainable spelling score. Use Levenshtein Distance when you need the edit count without a percentage. Use a visual diff when the task is to locate changes between versions and decide which edits to accept.

Different tools can calculate percentages differently, so do not expect their numbers to match. Neither a diff nor a similarity score establishes originality, ownership, attribution or truth. Those questions require provenance and judgment beyond string comparison.

Keep a reviewable record

For a tentative shortlist, preserve both original values with the score and explain why a candidate deserves attention. Review any names, amounts, dates, units and conditions before changing stored data. Do not automatically merge people, payments or legal records from a threshold alone.

A useful final check is simple: read the changed wording, verify important facts against their source and record the reason for the decision. The number can organize attention, but it should not replace that decision.

Apply the steps from this guide directly in your browser.

Frequently asked questions

Does 90 percent similarity mean two texts have the same meaning?

No. The percentage measures character edits relative to the longer length. Negation, numbers or conditions can change meaning while leaving many characters shared.

Why do different comparisons return the same percentage?

The formula normalizes the edit count by length. Different changes and different input lengths can yield the same ratio; the inputs still need direct review.

Does the page ignore spaces, case or Unicode differences?

It trims outer whitespace and requires non-empty values. Case, internal spaces and code-point differences remain; the similarity calculation does not perform Unicode normalization.

Can I use the score to merge records automatically?

There is no universally safe threshold. Preserve the originals and verify important identifiers, facts and conditions before changing records. A string score is not an identity or authorization check.