See exactly what changed between two versions
This text compare tool puts two versions next to each other and marks every difference: added lines in green with a + sign, removed lines in red with a − sign, and inside changed lines, only the words that differ. Colour and symbol always go together, so the result is readable for colour-blind users too.
Typical uses: checking what was edited in a tenancy agreement or an employment contract before you sign, reviewing changes to an article or a dissertation chapter, comparing two submissions of the same homework, or finding the setting that changed in a configuration file or in code.
How to compare two texts
- Paste the first version into “Original text” and the second into “Changed text”, or drop a text file onto either box (button “Open a file”).
- The diff appears as soon as you stop typing; “Compare” runs it again.
- Pick “Side by side” (two numbered columns) or “Unified” (one column, removed lines then added lines).
- Jump between differences with “Previous” and “Next”, or the P and N keys. “Swap texts” exchanges the two boxes.
Reading the result
Four counters sum up the comparison: lines added, removed, changed and similarity. Similarity is twice the number of identical lines divided by the total lines of both texts. Example: take a 20-line original, delete two lines near the top, reword one line in the middle and add three lines at the end. The new version has 21 lines, 17 untouched. The tool shows 3 lines added, 2 removed, 1 changed and 82.9% similarity (2 × 17 ÷ 41).
With “Collapse unchanged sections”, only 3 lines of context stay visible around each difference; a button reveals the rest. Two identical texts give the message “No differences”.
Line, word or character diff
The comparison works line by line first, the right scale for code and lists, then refines inside each changed line. “By word” highlights the replaced words, best for prose. “By character” catches a single letter, digit or comma, handy for a sort code, a postcode or a typo.
Options to ignore some differences
- Ignore case: “London” and “LONDON” count as the same, useful when a heading was switched to capitals.
- Ignore trailing spaces: invisible spaces left at line ends by an editor no longer count.
- Ignore all whitespace: re-indented code shows only the real edits.
- Ignore blank lines: paragraphs spaced differently no longer look changed.
Windows (CRLF) and Unix (LF) line endings are always treated the same.
The unified diff format
“Copy diff” and “Download” produce a unified diff (.diff or .patch): two headers starting with --- and +++ name the files, then each block opens with a line such as @@ -12,7 +12,8 @@ (from line 12, 7 lines in the original, 8 in the new version). Inside a block, a line starting with - was removed, with + added, and with a space unchanged.
Privacy and limits
All processing happens in your browser: no text is sent over the internet. That makes it safe for an NDA, a medical letter or internal source code. Nothing is kept unless you tick “Remember texts on this device”.
The tool reads plain text files. It does not open PDF files or word processor documents directly: copy their text and paste it in.
Frequently asked questions
Are my texts uploaded anywhere?
No. The comparison runs on your device; once the page has loaded, it even works offline.
Why is a line shown as removed and added?
Within a block, lines are paired in order and the leftovers count as added or removed. A line moved elsewhere shows up as removed in one place and added in another.
Can the .patch file be applied to the original?
Yes, it is a standard unified diff with 3 lines of context that the patch command accepts. Leave the ignore options unticked if the patch must rebuild the new version exactly.
How much text can it handle?
There is no fixed limit: two 10,000-line files with about fifty changes compare in well under a second.