Back to All Tools

Text Diff Viewer

Compare two pieces of text and see exactly what changed — by line or by word.

Runs entirely in your browser — nothing is uploaded
+0 · −0

About the Text Diff Viewer

The Text Diff Viewer compares two blocks of text and marks exactly what changed. You paste an original version on the left and a revised version on the right, and the tool shows one combined result: added text on a green background, removed text struck through in red, and unchanged text in plain gray. It catches the one word or line you would miss eyeballing two nearly identical paragraphs.

Both boxes start with sample sentences so you see output immediately. As you type or paste, the tool recomputes the diff on every keystroke using the JavaScript diff library. You pick the granularity with two buttons: By line compares whole lines, and By word breaks the comparison down to individual words. A running tally at the top right counts how many segments were added and removed, as a green plus and a red minus.

The line-by-line comparison runs in the page, so it is free, needs no account, and never uploads your text. The diff library loads client side and the comparison happens on your own machine, so the text you paste is never uploaded. That matters when you are comparing a contract clause, an unreleased draft, or config you would rather not send anywhere. Nothing to install, no character quota to hit.

How to use the Text Diff Viewer

  1. 1Paste or type your first version into the Original box on the left.
  2. 2Paste or type the second version into the Changed box on the right.
  3. 3Click By line to compare whole lines, or By word to compare word by word within the text.
  4. 4Read the Diff panel below, where green highlights are additions and red strikethrough marks removals.
  5. 5Click Clear to empty both boxes and start a fresh comparison.

What you can use it for

Proofreading two drafts

Drop the earlier draft of an email or article on the left and your edited version on the right, then switch to By word to catch a single changed name, number, or negation that a quick reread would skip over.

Reviewing pasted config

Compare a working config file against one that broke by pasting both in. By line mode lines them up so you can spot the setting that was added, deleted, or edited without opening a terminal.

Checking a quote or citation

Paste the source text and the version you copied into your document to confirm you transcribed it exactly. Dropped or altered words show struck through in red, so a mistyped quote stands out at a glance.

Line diffing versus word diffing

By line, the tool asks whether each whole line matches. If you change one word in a ten word line, the entire old line is marked removed and the new line is marked added, because at line granularity they are simply two different lines. That is ideal for code and config, where a line is the natural unit and you want to see which lines moved.

By word, the tool splits the text into words and compares those, so an edit to a single word leaves the surrounding words untouched and only that word shows red and green. That is what you want for prose, where most of a sentence survives an edit. Neither mode is smarter; they split the text at different boundaries before comparing, which changes how coarse or fine the highlighting is.

Frequently asked questions

Is my text sent to a server?

No. The diff runs completely in your browser using a library that loads on the page. Nothing you type in the Original or Changed boxes leaves your device, so you can compare private or unpublished text without it being uploaded or stored anywhere.

What do the plus and minus numbers mean?

They count the number of changed segments the diff found, not the number of words or characters. The green plus is how many added blocks appear and the red minus how many removed blocks appear, so one edited sentence can show as both an addition and a removal.

Can I upload files or download the result?

No. The tool works with text you paste or type directly into the two boxes, and there is no file upload, export, or copy button. To keep the diff, select the highlighted text in the Diff panel and copy it yourself, or take a screenshot.

Is there a limit on how much text I can compare?

The code sets no character limit, so you can paste long passages. Very large inputs may compute more slowly because the diff reruns on every keystroke, but for typical paragraphs, emails, and config files the result updates instantly.

Does it show changes in place or side by side?

It shows a single merged view, not two columns. The Diff panel weaves the versions together: unchanged text once in gray, added text in green, and removed text struck through in red, so you read one continuous block instead of scanning two panels.