Skip to content
XUtilHub

Diff Checker – Compare Two Texts Online

Compare two texts and highlight the differences line by line and word by word. Side-by-side or unified view. Free, private, in your browser.

  • Free, no sign-up
  • Runs in your browser, nothing uploaded
Original text
Changed text

About the Diff Checker

Paste two versions of a text to see exactly what changed. Added lines are green, removed lines are red, and changed words inside a line are highlighted. Switch between side-by-side and unified views.

Key features

  • Line-by-line comparison with word-level highlights
  • Side-by-side or unified (+/−) view
  • Smart pairing: edited lines line up with their new version
  • Ignore case and whitespace differences
  • Collapse unchanged lines to focus on changes
  • Private: both texts stay in your browser

Compare two texts and spot every change

Whether you're reviewing contract revisions, checking what an editor changed in your article, comparing two config files or finding the difference between two lists, the diff checker shows exactly what was added, removed and changed.

Reading the result

ColorMeaning
Green line, +Added in the changed text
Red line, −Removed from the original
Darker highlight inside a lineThe specific words that changed
⋯ N unchanged linesIdentical lines hidden by "Only show changes"

Side-by-side vs unified view

  • Side by side places the original on the left and the changed text on the right, which is easiest for reading prose and documents.
  • Unified lists removed lines (−) followed by added lines (+), like git diff. It's more compact and works well on narrow screens.

Options

  • Ignore case treats Hello and hello as equal.
  • Ignore whitespace ignores leading/trailing spaces and treats runs of spaces as one, which helps with re-indented code.
  • Only show changes hides long runs of identical lines, keeping three lines of context around each change.

Common uses

  • Writers and editors: compare drafts and track edits.
  • Developers: compare snippets, config files or API responses (for JSON, also try the JSON Compare tool).
  • Data cleanup: find which rows differ between two exports.
  • Legal and business: check what changed between contract versions.

Clean texts before comparing with Remove Extra Spaces or Sort Text Lines, so line order and spacing don't create noise.

How to use the Diff Checker

  1. Type or paste your text into the input box.
  2. Choose the options you want.
  3. The result updates instantly as you type.
  4. Copy the output or download it as a .txt file.

Frequently asked questions

How does the diff checker work?

It uses the Myers diff algorithm, the same approach used by Git, to find the smallest set of added and removed lines. Lines that were edited rather than replaced are paired up, and the changed words inside them are highlighted.

Can I compare code?

Yes. The comparison works on any plain text, including source code, JSON, CSV, config files and logs. Turn on 'Ignore whitespace' to skip indentation changes.

Is there a size limit?

There's no fixed limit. Tens of thousands of lines compare quickly. For extremely different large files, the tool falls back to showing the blocks as fully replaced to stay responsive.

Are my texts uploaded?

No. The comparison runs entirely in your browser, so it's safe for contracts, drafts and private code.

Is my text sent anywhere?

No. All text tools run locally in your browser.

Do these tools support Unicode?

Yes. They handle Unicode text, including emoji and accented characters.

Last updated:

Related Text tools