{jsonbody.com}

Text Diff Checker

Compare two texts online side by side. Added, deleted and changed lines are highlighted, and markers jump between each difference. Free, private, no upload.

Loading…

See what changed between two texts

Paste the original into Text 1 and the new version into Text 2, then press Compare. The two versions are aligned side by side, with added, removed and modified lines highlighted. Finding one changed line in a long document by eye is slow and unreliable, while a diff tool makes every change obvious.

On long documents, use the marker strip on the right to jump straight to each change. Press Edit to go back, adjust either side and compare again.

What people use it for

  • Comparing two versions of a config file to find why a deployment behaves differently.
  • Checking what an editor changed in an article or contract before you accept it.
  • Spotting differences between a log from a working run and a failed one.
  • Reviewing SQL, code or an API response when you do not have a Git repository to hand.

Example

Two versions of a short config. A line-based comparison reports one modified line and one added line, while the unchanged lines stay plain.

Text 1, Text 2 and the differences
Text 1                   Text 2
host: localhost          host: localhost
port: 8080               port: 9090
                         debug: true

Modified: port: 8080 -> port: 9090
Added:    debug: true

Getting cleaner results

A diff treats every character as meaningful, so differences you do not care about can hide the ones you do. A few small steps before comparing can help a lot.

  • Files from Windows and Linux use different line endings, and pasting usually normalises these. Compare in a dedicated tool if the endings themselves are the issue.
  • Trailing spaces and tabs show up as changes. Our Word Counter page has buttons to tidy spacing.
  • If you are comparing JSON objects, use our JSON Compare tool, since key order and formatting do not change the meaning. Or sort keys with the JSON Minifier and Beautifier first.
  • Format SQL or XML with the matching formatter on both sides, so that only real changes remain.

Privacy

Comparing contract drafts or production configs raises a fair question about where that text goes. The comparison runs in your browser and the text is not uploaded to a server, so nothing is stored once you close the page. As with any web page, take care on shared computers.

Frequently Asked Questions

Does it compare by word or by line?

It aligns the texts line by line and highlights lines that were added, deleted or modified. This suits config files, code and structured documents especially well.

Can I compare Word or PDF files?

Copy the text out of each file and paste it in. Formatting such as bold or font size is not compared, only the text.

Why are lines that look identical marked as different?

They probably differ in invisible characters such as trailing spaces, tabs or non-breaking spaces.

How do I go back after comparing?

Press Edit. Your text is still there, so you can change it and press Compare again.