Free Online Text Compare

Compare two texts with similarity percentage and side-by-side highlighted differences.

edit Text A
Chars: 0 Words: 0 Lines: 0
edit Text B
Chars: 0 Words: 0 Lines: 0
Similarity: -- Levenshtein distance: --

Key Features

analytics

Similarity Percentage

Levenshtein distance algorithm computes an exact similarity score between two texts.

visibility

Side-by-Side Comparison

Added, removed, and unchanged lines shown with red/green highlighting side by side.

search

Multiple Granularity

Line, word, and character-level comparison with inline highlighting of exact changes.

lock

Privacy First

All processing happens locally in your browser. No data ever leaves your device.

Frequently Asked Questions

Usage
How is the similarity percentage calculated?expand_more
The similarity score uses the Levenshtein distance (edit distance) between the two texts. The formula is: similarity = (1 - distance / max(lenA, lenB)) * 100%. Levenshtein counts insertions, deletions, and substitutions needed to transform one text into the other. A score of 100% means the texts are identical; lower scores indicate more edits required.
Does a 90% similarity score mean the texts are plagiarized?expand_more
Not necessarily. The similarity score is an objective edit-distance measurement and does not make judgments about originality. Two code snippets following the same pattern, legal document templates, or boilerplate text can show 90%+ similarity without being plagiarized. The score is a quantitative starting point — you must interpret it in context and review the visual diff to understand what actually changed.
Why does the similarity percentage differ between Line and Word modes?expand_more
The similarity percentage is always calculated at the character level across the entire text using Levenshtein distance, regardless of display granularity. The Line, Word, and Char options only affect how the visual diff is rendered — they do not change the similarity score.
What is the size limit for text comparison?expand_more
The tool runs entirely in your browser using the Levenshtein distance algorithm, which has O(n*m) time and memory complexity. For texts under 5,000 characters, comparison is near-instant. Above 10,000 characters, you may notice a delay. For files larger than 50KB, consider using a native tool like diff or a desktop comparison application.
Does it support non-English text, like Chinese or Arabic?expand_more
Yes. The Levenshtein distance algorithm and all comparison logic operate on UTF-8 character sequences, making them language-agnostic. Chinese, Japanese, Korean, Arabic, Cyrillic, and other scripts are fully supported. Each Unicode character counts as one unit for distance calculation. Emoji and other multi-byte characters are also handled correctly.