1. All tools
  2. Text diff

How do I compare two texts and see what changed?

Paste the original on the left and the changed version on the right. The page highlights what was added and removed — by line, by word or by character — and counts the changes. You can ignore case or whitespace, fold long unchanged sections, and copy or download the result as a standard unified .diff patch.

Runs entirely in your browser · nothing is sent · no account

  1. Paste the original text on the left.
  2. Paste the changed text on the right.
  3. Read the highlighted changes, or export a .diff.

What this page can do

  • Line, word and character comparison
  • Ignore case and ignore whitespace options
  • Folds long runs of unchanged lines
  • Line numbers for both versions
  • Counts added and removed lines, words or characters
  • Copy or download a unified .diff patch

When to use this page

  • Checking what an editor or co-author changed in a document.
  • Comparing two versions of a config file, contract clause or code snippet.
  • Spotting a single changed character in two long, similar strings.

When to use something else

  • You need to compare Word, PDF or Excel files directly — copy the text out first.
  • You need a three-way merge or to apply the changes — use Git or a merge tool.
  • You are comparing whole folders or very large files of many megabytes.

How it compares with other options

Git, VS Code and desktop merge tools compare files on disk, understand repositories and can merge changes back. Word’s “Compare documents” keeps formatting. This page is for the quick case: two pieces of text in your clipboard, compared instantly without installing anything or uploading either version. It uses the same Myers diff algorithm that Git uses by default, and its .diff export can be applied with git apply or patch.

Where your text goes

Nowhere. Everything is computed by your own browser as you type. Nothing is sent to a server, saved to an account or written to storage — close the tab and it is gone. You can check it yourself: open your browser’s network panel — the page still loads its own code and any ads, but no request carries what you typed.

Questions about this tool

What is the difference between line, word and character mode?

Line mode marks whole lines as added or removed — best for code, lists and config files. Word mode highlights changed words inside running text — best for prose. Character mode shows every single changed character — best for IDs, URLs or short strings that look identical.

What does “ignore whitespace” do?

In line mode it ignores spaces and tabs at the start and end of each line, so re-indented lines are not reported as changed. In word mode it ignores differences in the amount of spacing between words.

What can I do with the .diff file?

It is a standard unified diff. You can attach it to a code review, read it in any code editor, or apply it to the original file with git apply changes.diff or patch < changes.diff. The patch always uses line mode, whichever view you are looking at.

How large can the texts be?

Up to about 3 million characters combined. Below 150,000 characters the comparison updates as you type; above that, press Compare. Very different large texts take longer, because the work grows with the number of changes.

Other tools you may need