Text Diff Checker

Compare two texts and highlight the differences.

diff
compare
text
changes
code review

About this tool

Compare two blocks of text side-by-side and see exactly what changed. Highlights additions, deletions, and modifications. Perfect for code reviews, document comparison, and version tracking.

Features

  • Compare two blocks of text side-by-side
  • Highlight additions, deletions, and modifications
  • Line-by-line or inline diff view
  • Perfect for code reviews and document comparison

How to Use

  1. Paste the original text in the left panel
  2. Paste the modified text in the right panel
  3. View highlighted differences between the two texts
  4. Use the diff output for code reviews or change tracking

Frequently Asked Questions

What algorithm does the diff use?

A variant of the Myers diff — the same algorithm Git and most diff tools implement. It finds the longest common subsequence between the two inputs in near-linear time and highlights everything else as added or deleted. For very long inputs (100 kB+), expect it to slow down.

Can I diff two JSON files structurally?

This tool does a line-level text diff, which works on JSON but will flag reformatted-but-equivalent JSON as different. For true structural diff (order-independent, type-aware), use a dedicated JSON diff tool like json-diff or a VS Code extension; line diffing is coarser.

What's the difference between line diff and character diff?

Line diff shows whole changed lines. Character diff highlights the specific characters within a line. Line diff reads faster for prose and code; character diff is better when the change is a typo or a single-word edit. This view defaults to line diff with inline character highlighting on changed lines.

Is my input stored?

No — the diff runs entirely in-browser. That matters when you're comparing unreleased code, customer data, or confidential documents. Both pastes are held only in the open tab and disappear on refresh.

Why does git's diff look different than the one shown here?

Git diffs include context lines (the default 3 lines above and below each change) and use unified-diff format. This view is more visual — side-by-side with highlighted changes. They're equivalent information, just rendered for different audiences.