Skip to content

Text Diff

Compare two versions of a text by line, word or character and see additions and removals highlighted. Private: nothing is uploaded.

Runs in your browser. Nothing is uploaded.

Compare by

About the Text Diff

Spotting what changed between two versions of a contract, essay, configuration file or piece of code is slow and error-prone by eye. This tool compares two texts and highlights exactly what was added and what was removed.

Compare by lines for code and config files, by words for documents and prose, or by characters to catch single-letter typos. It uses the Myers diff algorithm, the same approach as git diff, and runs in your browser, so confidential documents are never uploaded.

How to use it

  1. Paste the original version on the left and the changed version on the right.
  2. Choose to compare by lines, words or characters.
  3. Optionally ignore differences in letter case (and, for lines, whitespace).
  4. Read the result: additions are highlighted green, removals red with a strike-through.

Examples

Contract revisions

Compare by words to see that “30 days” was changed to “14 days” in a long agreement, without reading both versions in full.

Config files

Compare two versions of a .env or YAML file by lines to see which settings changed.

Proofreading

Compare by characters to find a single changed letter or punctuation mark between two drafts.

Limitations

  • Shows one combined view rather than two side-by-side columns.
  • Moved paragraphs appear as a removal plus an addition; the tool doesn't detect moves.
  • Formatting (bold, fonts) isn't compared, only the plain text. Copy from Word or PDF loses formatting.
  • Very large texts in character mode can be slow; use line mode for long files.

Frequently asked questions

Should I compare by lines, words or characters?

Lines for code, data and config files; words for documents, articles and contracts; characters when you're looking for tiny changes such as typos or punctuation.

Why does a small edit show a whole line as changed?

In line mode, any change within a line marks the whole line. Switch to words or characters to see exactly what changed inside it.

Are Windows and Mac line endings treated as differences?

No. Line endings are normalised before comparing, so the same text saved on Windows and macOS is shown as identical.

Is my text sent to a server?

No. The comparison runs entirely in your browser, which makes it safe for confidential documents and code.

Related tools