Text Diff Checker

Paste an original and a changed version and see exactly what is different. Lines are compared with a Myers diff, the same family of algorithm used by version-control tools, and inside changed lines the individual words that changed are marked. Every added or removed line carries a + or − sign, so nothing relies on colour alone.

Transform & Compare Runs in your browser

Compare Two Texts

How to Use the Text Diff Checker

  1. Paste the original text in the left box and the changed version in the right box.
  2. Optionally ignore upper and lower case or differences in spaces, and choose to show only changed lines with context.
  3. Read the summary and the table: lines marked + were added, lines marked − were removed, and underlined or struck-through words show what changed inside a line.
  4. Copy or download the plain-text version of the differences.

About This Tool

Writers and editors comparing drafts, developers checking config files or snippets, students comparing sources and anyone who needs to know what changed between two versions.

Input: Two plain texts  ·  Output: Line and word differences.

Features and Limitations

Features

  • Line diff using the Myers algorithm, plus a word-level diff inside changed lines.
  • Added and removed lines are labelled with + and − and with hidden text for screen readers, not only coloured.
  • Summary with added, removed and unchanged line counts and a similarity percentage.
  • Collapse long unchanged stretches to focus on the changes.

Limitations

  • The comparison is by line: moving a paragraph shows as a removal in one place and an addition in another.
  • To stay responsive the tool refuses texts over 1,000,000 characters or with more than about 3,000 changed lines; compare smaller sections instead.
  • A trailing line break at the very end of a text is ignored.
  • Word-level highlighting is skipped for very long lines.
  • Results are computed in your browser; nothing you enter is sent to a server.

Example

Comparing “red\ngreen\nblue” with “red\ngreen apple\nblue” shows 1 line removed (green), 1 added (green apple), 2 unchanged, and marks the inserted word “apple”.

Frequently Asked Questions

How does the diff work?

Each line is turned into a token and the shortest sequence of insertions and deletions that turns the original into the changed text is found with the Myers algorithm. Lines in a changed block are then paired and compared word by word.

Can I ignore whitespace differences?

Yes. Tick Ignore differences in spaces and tabs and lines that differ only in leading, trailing or repeated spaces count as unchanged.

Why is a moved paragraph shown as a delete and an add?

Line-based diffs do not track moves; they only report the minimal set of added and removed lines.

Is there a size limit?

Each text may be up to 1,000,000 characters, and the tool stops if the texts differ in more than about 3,000 places, to keep your browser responsive.

Related Tools

More like this: all Transform & Compare tools, all Text & Writing tools or the TinySandy home page.