How to compare two texts or strings online

Two files that look identical can still differ because of an extra space, a different quotation mark or a hidden line break. The comparison tool finds these changes in seconds.

Compare two texts in three steps

  1. Open Text diff — nothing you paste leaves your browser.
  2. Paste the original version on one side and the new version on the other.
  3. Read the highlighted lines: added, removed and changed are colour-coded.

Differences people miss

  • Extra spaces — often invisible, but they can still make two lines different.
  • Different line breaks — text saved by different systems can make every line appear changed.
  • Smart quotes and dashes — a word processor silently swaps " for “ and - for –.
  • Special spaces — copied from web pages, they can look exactly like a normal space.
  • Capital letters — ID and id may be treated as different text.
  • Invisible characters — text copied from PDFs or chat apps can contain hidden marks.

Comparing structured data

JSON and code can look different only because of spacing or layout. Format both sides first with the JSON formatter so their spacing matches, then compare them. If you only need a quick yes-or-no check, use the Hash generator to create a short fingerprint for each text. Matching fingerprints mean the text is identical.

FAQ

Is the comparison private?

Yes. The comparison happens inside your browser. Nothing is uploaded, recorded or stored, which matters when you are comparing contracts or configuration.

Can I compare two files instead of pasted text?

Open each file in Universal file preview, copy the contents, and paste both sides into the diff. For PDFs, run Extract PDF text first.

Is there a size limit?

No hard limit, but very large inputs (hundreds of thousands of lines) are limited by your device's memory rather than by us.

Tools: Text diff · JSON formatter · Hash generator

← Back to Learn