Skip to content
SnapTools

Text Diff

Runs in your browser

Compare two blocks of text line by line and see exactly what was added, removed and left alone. Runs entirely in your browser.

About this tool

Comparing two versions of anything by eye is unreliable — the change you are looking for is usually the one you skim past. A diff removes that problem by aligning the two texts and marking only what differs. This tool uses a longest-common-subsequence alignment, the same approach version-control systems use, so a block inserted in the middle is shown as an insertion rather than shifting every following line into a false difference.

How to use

  1. Paste the original text on the left and the changed text on the right.
  2. Optionally ignore whitespace or case, which hides reformatting-only changes.
  3. Read the result: red lines were removed, green lines were added.

When to use this tool

  • Checking what changed between two versions of a document or contract.
  • Comparing two config files across environments.
  • Spotting differences between two lists of IDs or emails.
  • Reviewing an edit before pasting it back into a system.

Tips

  • Turn on 'ignore whitespace' when comparing reformatted code or text — it removes noise from indentation changes.
  • For structured data, JSON Diff is better: it ignores key order, which a text diff cannot.
  • Very large inputs fall back to a simpler line-by-line alignment; the result says so when that happens.

FAQ

Is my text uploaded?
No. The comparison runs in your browser. Nothing is transmitted or stored.
Why is a moved block shown as a delete and an add?
Line diffs align sequences; they do not track movement. A block that moved reads as removed from one place and added in another, which is also how git reports it by default.
Is there a size limit?
A full alignment is used up to roughly two thousand lines on each side. Beyond that it switches to a straight line-by-line comparison to avoid exhausting memory, and tells you it did.