Browser-Based · Instant · Free

Text Compare.
Find Every Difference.

Paste two versions of a text and see what was added, removed or changed — line by line and word by word. Your text stays in your browser.

Text Compare

0 lines

0 lines

100% Private
The comparison runs in your browser. Contracts, code and drafts are not sent to any server.
Word-Level Detail
Changed lines show the exact words that differ, not just the whole line.
Files Too
Open .txt, .csv, .json, code and subtitle files, up to 10 MB each.

How to Compare Two Texts

1
Add the original

Paste the older version into the left box, or click Open file to load a text file.

2
Add the changed version

Paste the newer version into the right box.

3
Click Compare

Differences appear below. After the first comparison, the result updates as you edit either text.

Reading the result

  • Red lines marked − are only in the original text: they were deleted or replaced.
  • Green lines marked + are only in the changed text: they were added or are the replacement.
  • On edited lines, the exact words that changed are highlighted in a stronger colour. When a line was rewritten almost completely, the whole line is marked instead, because word highlights would be noise.
  • Line numbers belong to each text, so you can find the same place in your own file.
  • Show only changes hides long stretches that are the same and keeps three lines around each change. Click the grey bar to reveal the hidden lines.
  • Side by side puts the two versions next to each other. Inline lists removed lines followed by added lines, which is easier to read on a phone.

The options

What each option ignores

OptionTreats as the sameUseful for
Ignore caseTotal and TOTALText that was retyped, SQL, headings
Ignore whitespaceSpaces or tabs at the start or end of a line, and several spaces in a rowRe-indented code, text copied from PDFs or web pages
Ignore blank linesEmpty lines added or removedDocuments where only paragraph spacing changed

Line breaks from Windows (CR LF) and from Mac or Linux (LF) are always treated as the same, so a file saved on another system does not show every line as changed.

Comparing documents and files

  • Plain-text files — .txt, .csv, .json, .xml, .md, subtitles and source code — open directly with the Open file button or by dropping them on a box.
  • Word and PDF files are not plain text. Copy the text out of them, or convert them first with Word to Text or PDF to Text. Text taken from a PDF often breaks lines in different places, so turn on Ignore whitespace and Ignore blank lines.
  • Download .diff saves the changes in the standard unified diff format used by Git and the patch command. It always describes the exact texts, so the ignore options do not change it.

Frequently Asked Questions

Is my text uploaded anywhere?

No. The comparison is done by JavaScript in your browser. The text you paste or open is not sent to our server or stored, which makes this safe for contracts, code and private documents.

How long can the texts be?

Files up to 10 MB each can be opened, and texts of many thousands of lines compare in a second or two. Very large texts that are almost completely different may take too long; the page then asks you to compare smaller parts.

Can I compare Word or PDF documents?

Yes, by comparing their text. Copy the text out of each document, or convert both to plain text with our Word to Text or PDF to Text converter, and paste or open the results here. Formatting such as bold or fonts is not compared.

What is a .diff file?

A .diff (or patch) file lists the changed lines with a few lines of context, marked with − and +. Developers use it to review changes or apply them to another copy of the file with Git or the patch command.