Text Compare (Diff Checker)
Paste two versions of any text or code to see exactly which lines changed.
Runs in your browser · nothing is uploaded
How to use the Text Compare
- Paste the original text on the left and the changed text on the right, or open a file on each side.
- Removed lines are shown in red with a minus, added lines in green with a plus, and each line keeps its original line number.
- Turn on Ignore whitespace or Ignore case if indentation or capital letters should not count as changes.
- Turn on Changes only to hide unchanged lines and focus on what is different.
About this tool
This diff checker uses the Myers algorithm, the same one git uses by default, so it finds the smallest set of added and removed lines that turns the first text into the second. That keeps the output short and readable even when changes are scattered through a long file.
It works with any plain text: source code, logs, SQL queries, CSV exports, essays or configuration files. Windows and Unix line endings are treated the same, so a file saved on another system does not show every line as changed.
Comparing student solutions, checking what changed between two versions of a config file, and spotting the one different line in two long logs are the most common uses.
Frequently asked questions
›What does Ignore whitespace do?
It treats lines as equal when they differ only in spaces or tabs, for example after re-indenting code. Leading and trailing spaces are ignored and runs of spaces count as one.
›Does it show changes within a line?
It works line by line: a changed line appears as one removed line and one added line, next to each other, so the difference is easy to spot.
›Is there a size limit?
It handles files with tens of thousands of lines. Only when two long texts are almost entirely different does it stop and say so, rather than freezing your browser.
›Is my data sent anywhere?
No. The tool runs entirely in your browser with JavaScript. What you paste is never uploaded, logged or stored on our servers, so it is safe to use with internal data, though you should still treat secrets with care on shared computers.
›Can I compare JSON with it?
You can, but the JSON compare tool is better for that: it ignores key order and formatting and lists changed values by path.