Diff Checker
Compare text by line, word or character — unified or side by side — and export or apply patches
How it works
Paste an original and a changed version. Lines mode runs Myers' diff over lines and pairs changed lines so the exact words that differ are highlighted inside them; switch to Words or Characters to diff the whole text as one stream. View the result unified (like a patch) or side by side with line numbers. Whitespace can be compared, ignored at line edges, or ignored entirely; case can be ignored; and with JSON: sort keys, two JSON documents are compared with keys sorted and formatting normalised so only real differences show. Long unchanged runs fold to a few lines of context — expand them as needed. The header shows added, removed and modified counts and how similar the texts are. Copy or download the result as a standard unified .patch, or paste a unified diff and apply it to the original (with optional fuzz) to produce the changed text. Share writes both texts into the link, compressed.
Questions
What is the difference between the three modes?
Lines treats each line as a unit and, for changed lines, highlights the words that differ — best for code and config. Words and Characters diff the whole text as one stream, which suits prose or short strings.
Can it ignore whitespace or letter case?
Yes. Whitespace can be compared exactly, ignored at the start and end of lines, or ignored everywhere; Ignore case compares letters case-insensitively. The original text is still shown — only the comparison changes.
How do I compare two JSON documents?
Turn on JSON: sort keys. When both sides parse as JSON they are pretty-printed with keys sorted before diffing, so key order and formatting differences disappear and only value changes remain.
Can I get a patch file?
Yes — Copy patch or .patch gives a standard unified diff (as produced by diff -u or git) with the chosen number of context lines. Apply patch does the reverse: paste a unified diff and apply it to the original, with a fuzz factor for slightly shifted context.
Does it handle large files?
It uses Myers' algorithm (the same as git), so files with thousands of lines diff instantly. Intra-line highlighting is skipped for lines over 2,000 characters, and unchanged regions fold to keep the view short.
Is my text private?
Yes — everything runs in your browser. Text only leaves your device inside a link you create with Share (compressed into the URL fragment).