Compare two texts side by side
When a document goes through several drafts, it is hard to see what actually changed. This diff checker compares two versions and highlights every difference: green for text that was added, red for text that was removed. Choose to compare by line, word or character, and optionally ignore case or whitespace. The comparison runs entirely in your browser, so you can safely check contracts, code and confidential documents.
Features
- Three levels of detail: lines (with line numbers for both versions), words, and individual characters.
- Ignore case and ignore whitespace options to hide differences that don't matter.
- Summary counts of additions and deletions, plus a clear message when the texts are identical.
- Swap button to reverse which text is treated as the original.
- No size limits or uploads: long documents are compared locally.
What people compare
Contracts and policies. Check exactly what the other side changed in a revised agreement before you sign it. Word mode highlights changed terms inside long clauses.
Code and configuration. Compare two versions of a function, a .env file or a server config without setting up version control. Line mode with line numbers reads like a familiar code-review diff.
Writing and editing. See the edits an editor or a grammar tool made to your article, or compare a translation with its revised version.
Data and lists. Paste two exports to find rows that were added or removed. For JSON data, format both sides first with the JSON Formatter (with sorted keys) so the comparison focuses on real differences.
How diffing works
A diff algorithm looks for the longest common subsequence — the largest amount of text both versions share in the same order — and reports everything else as insertions or deletions. This tool uses the Myers algorithm, the same family of algorithms used by Git and most code review tools. Because it searches for the smallest edit, a moved paragraph appears as one deletion and one insertion rather than as a "move".
If you only want to remove repeated entries from a list, use Remove Duplicate Lines instead.