Text Diff Checker – Compare Two Texts and See Exactly What Changed
A text diff checker takes an original and a revised version of the same content and shows you precisely what moved between them: which lines were added, which were deleted, and which were rewritten in place. Reading two drafts side by side and hunting for the delta by eye is slow and unreliable — a diff makes the change explicit, down to a single character if you need it. This tool runs entirely in your browser, so drafts, configuration files, API payloads, and log excerpts never leave your device.
How the comparison works
The engine implements Myers' difference algorithm, the same shortest-edit-script approach used by git diff. It finds the smallest set of insertions and deletions that turns the original into the modified version, then pairs adjacent deletions and insertions so both panes stay aligned row for row. On top of that edit script the tool computes the Levenshtein edit distance — the minimum number of single-character insertions, deletions, or substitutions needed to convert one text into the other — and derives a similarity score:
similarity = (1 − distance ÷ max(lengthA, lengthB)) × 100
Two identical texts score 100%. Two texts with nothing in common approach 0%. Because the distance matrix costs O(m × n), the exact value is computed only below roughly 10,000 characters per pane; above that a line-level estimate is shown instead so the page never freezes.
Line, word, and character granularity
Line mode is the classic diff and the right default for code, YAML, .env files, SQL, and logs — anything where a line is the natural unit of change. Word mode compares individual words, which is what copy editors and translators want: a single reworded phrase inside a long paragraph is highlighted in place instead of flagging the whole sentence. Character mode is the finest setting and exists for the cases that matter most and are hardest to spot — a transposed digit in an order ID, a wrong character in a hash, a mistyped version string like ORDER-2024-A1938 versus ORDER-2024-A1983.
Normalization rules filter out noise
Most "differences" between two files are cosmetic. The ignore rules normalize both texts before the comparison runs, in a fixed order: line endings first, then per-line trimming, whitespace collapsing, blank-line removal, punctuation stripping, case folding, and finally optional line sorting for when order does not matter. If the two texts turn out to match only because of the rules you enabled, the result says so and lists exactly which rules were responsible — you never get a silent false match.
CRLF) compared against the same file saved on Linux (LF) can show every single line as changed. The line-ending badge above each pane tells you what you are dealing with, and normalizing endings makes the real edits visible again.Unified patch output
Switching to the unified view produces standard Git-style patch text with @@ hunk headers, + and - prefixes, and a configurable number of context lines. The output is copy-paste-ready for a code review comment, or downloadable as a .diff file. The same change list also exports as CSV — one row per change with line numbers and before/after values — or as a Markdown table.
Reading the statistics
Beyond the visual diff, the statistics panel reports lines added, removed, modified, and unchanged, word and character deltas, and the number of change blocks (hunks) — contiguous regions that differ. A high similarity score with many hunks means lots of small scattered edits; a lower score with one hunk usually means a single large rewrite. Each pane also reports its own line, word, character, and UTF-8 byte counts, which is worth remembering: multibyte characters make byte size larger than character count.
Practical uses
Writers compare two drafts of an article or email. Developers diff two versions of a config file outside of version control. QA engineers compare two API responses or log excerpts to isolate a regression. Students check what a reviewer changed. Localizers verify that only the intended strings moved after a batch update. And anyone can confirm that a find-and-replace or an automated transformation did exactly what it promised — nothing more.
Tips for a cleaner diff
Turn on Only changes to collapse long unchanged regions behind expandable separators when comparing large documents. Use Show whitespace when a line looks identical but still reports as changed — an invisible tab or trailing space is usually the culprit. Use Format JSON before diffing API payloads so formatting differences disappear and only real value changes remain. And if red and green are hard to distinguish, the colourblind-safe palette switches the highlighting to blue and orange while keeping the +, -, and ~ markers and screen-reader labels intact.