Text Diff Checker
Runs entirely in your browser
Compare two blocks of text line by line and see exactly what was added, removed or left unchanged. Everything happens directly in your browser.
How to use Text Diff Checker
- Paste the original text into the left box and the changed text into the right box.
- Turn on Ignore case or Ignore whitespace if you want those differences skipped.
- Click Compare Text.
- Review the line-by-line result below — added lines are green, removed lines are red.
Features
- Line-by-line comparison that highlights added and removed lines.
- Optional case-insensitive and whitespace-insensitive comparison.
- Summary counts for added, removed and unchanged lines.
- 100% client-side — your text never leaves your browser.
Example
Original text:
name: Alice
role: admin
active: true
Changed text:
name: Alice
role: editor
active: true
theme: dark
Comparing the two produces:
name: Alice
− role: admin
+ role: editor
active: true
+ theme: dark
Lines added: 2 · Lines removed: 1 · Lines unchanged: 2.
Tips for reading a diff
- Comparison works line by line, not word by word — changing a single word in a long line shows the whole line as removed and the whole line as added, rather than highlighting just the changed word.
- Turn on Ignore whitespace to trim each line and collapse repeated inner spaces before comparing, so text that was only reformatted (extra spaces, re-indentation) isn't reported as changed.
- Because the comparison finds the longest matching sequence of lines, a block of unchanged lines that moves to a different position is still recognized as unchanged, as long as its content matches exactly.
- Texts larger than roughly 2,000 lines on each side (about 4 million line-pair comparisons) are rejected with a message asking you to compare smaller sections — this keeps the comparison from freezing the browser tab.
Is Text Diff Checker safe?
Yes. Text Diff Checker runs its longest-common-subsequence line comparison locally in JavaScript, capped at roughly 2,000 lines per side to keep the tab responsive — neither text is ever uploaded to a server, and nothing is kept once you close or refresh the tab.
Frequently Asked Questions
How does Text Diff Checker compare text?
It compares the Original and Changed text line by line and finds the longest sequence of lines they share, then marks every remaining line as added or removed.
Can I ignore case or whitespace differences?
Yes. Turn on Ignore case to treat "Hello" and "hello" as the same line, or Ignore whitespace to ignore extra spaces and leading/trailing spaces when comparing.
What do the + and − marks mean?
A green line marked with + only appears in the Changed text. A red line marked with − only appears in the Original text. Lines with no mark are unchanged.