Text Compare — Find the Difference
Paste two versions of anything — a document, a config file, a contract — and see precisely which lines changed between them.
Comparison is line by line using a longest-common-subsequence algorithm, the same approach git uses, so unchanged blocks stay aligned even when lines are inserted or deleted in the middle.
How to use
- 1Paste the original version into the left box.
- 2Paste the changed version into the right box.
- 3Read the line-by-line diff, with additions and removals marked.
- 4Check the summary counts of lines added, removed and unchanged.
Frequently Asked Questions
How does the comparison work?
It uses a longest-common-subsequence algorithm, the same approach git uses for diffs. That keeps unchanged blocks aligned even when lines are inserted or deleted in the middle, instead of reporting everything after an insertion as changed.
Can it compare Word or PDF files?
Not directly. Copy the text out first — for PDFs, our PDF to Text tool extracts it in one click — then paste both versions here.
What do the ignore options do?
Ignore case treats Hello and hello as the same line. Ignore whitespace strips leading and trailing spaces and collapses repeated spaces, which is useful when indentation changed but the content did not.
Is my text uploaded anywhere?
No. The whole comparison happens in JavaScript in your browser, so it is safe for confidential documents and works offline.
Does it show which words changed within a line?
The comparison works line by line, so a line that changed at all is marked as changed. For prose, breaking long paragraphs onto separate lines before comparing gives a much more readable result.
Can I compare two versions of code?
Yes — that is what a line-based diff is best at. Indentation changes will show as differences, so use the whitespace option if you only care about real edits.