Text compare and diff checker

Compare two texts and see exactly what changed — line by line, word by word. Paste the original on the left and the revised version on the right.

Original 0 lines
Modified 0 lines

What a text comparison tool shows you

A text comparison tool answers one question: what is different between these two versions? Paste the original into the left panel and the revised version into the right, and the comparison runs automatically. Every line that exists only in the second version is marked as an addition, every line that exists only in the first is marked as a removal, and lines that were edited rather than replaced are shown as a pair with the individual changed words highlighted inside them. Nothing is uploaded — the comparison runs in your browser, which is why it is instant and why confidential contracts, medical notes or unreleased copy are safe to compare here.

That makes it equally useful whether you want to compare two texts word for word, compare two paragraphs after an edit, or compare two strings of code. The tool handles up to 3,000 lines per side, so a full chapter, a long config file or an entire terms-of-service document all fit comfortably.

How to find the difference between two texts

Comparing by eye fails quickly. Two versions of a paragraph that differ by one word look identical during a read-through, and the difference you are hunting for is usually the one you skim past. A diff does the comparison mechanically: it finds the longest sequence of lines the two texts share, then reports everything outside that sequence as inserted or deleted. Because it looks for the minimum set of edits, a single new sentence in paragraph three is reported as one addition rather than flagging every paragraph after it as changed.

The practical workflow is the same regardless of what you are checking. Put the older or official version on the left, put the newer or received version on the right, and read the coloured result from the top. Use Swap if you loaded them the wrong way round — the changes invert, so an addition becomes a deletion. Copy diff gives you the result in unified diff format, the same +/- convention Git and code review tools use, which pastes cleanly into an email or an issue tracker.

Text comparison terms explained

Search results for text comparison use several names for overlapping ideas. They are worth separating, because they answer different questions:

TermWhat it meansWhat it answers
DiffThe list of insertions and deletions that turns one text into the otherWhat exactly changed, and where
String compareA character-by-character check of two short pieces of textAre these two strings identical or not
Text matchA check for whether one text contains or equals anotherDo these texts correspond
Text similarityA score, usually a percentage, of how alike two texts are overallHow close are they, roughly
Paragraph comparisonA diff applied to prose rather than code, usually with word-level highlightingWhich sentences an editor touched

This tool is a diff, which is the most informative of the five: a similarity percentage tells you two documents are 94% alike, but a diff shows you the 6% and lets you decide whether it matters. If you only need to know whether two texts are byte-identical, the diff result will simply come back empty.

The history of diff

Comparing two versions of a text automatically is a 1970s invention. The original diff program was written by Douglas McIlroy at Bell Labs in 1974 for Unix, built on what became the Hunt–McIlroy algorithm for finding the longest common subsequence between two files. The idea proved foundational: every version control system since — from RCS through Subversion to Git — is essentially machinery built around diffs, storing and displaying changes rather than whole copies. The green-for-added, red-for-removed convention that this tool uses comes straight from that lineage and is now the universal visual language of change tracking, from GitHub pull requests to Wikipedia edit histories.

Line-level and word-level differences

The diff checker compares text at two levels of detail. At the line level it identifies which lines were added, removed, or modified. When a line is modified rather than completely replaced, the tool also runs a word-level comparison on that specific line pair, highlighting exactly which words changed inside it. This makes it easy to spot a single word correction in a long paragraph without reading the whole line twice.

Who uses a text diff checker

Writers use the diff checker to compare draft versions of an essay or article and see what they or an editor changed. Developers use it to compare config files, documentation, or any text that is not in version control. Students use it to compare their submission against a revised or corrected version. Translators use it to track changes in the source document between review cycles. Anyone who has two versions of a text and wants to know exactly what is different will find it useful.

Legal and contract review is a heavy user: comparing a returned contract against the version you sent catches the clause that was quietly reworded. Content teams compare a page before and after a rewrite to build a changelog. QA testers compare expected output against actual output. Academics compare a manuscript against the copy-edited proof before signing it off.

Comparison is often the second step rather than the first. If the two texts arrived with inconsistent formatting, running both through remove extra spaces or remove line breaks first strips out cosmetic differences so the diff reports only real edits. If you want length rather than difference, the word counter gives word and character totals for each version, and the duplicate line remover is the better choice when the question is which lines repeat within one list rather than how two lists differ.

Frequently asked questions

How does the text diff checker work?

Paste the original text in the left panel and the revised version in the right, and the comparison runs automatically — no button needed. Under the hood, a longest-common-subsequence algorithm computes the minimum set of insertions and deletions that turns one text into the other, the same approach the classic Unix diff tool pioneered. That minimality matters: instead of flagging everything after the first change, the result pinpoints only the lines and words that actually differ.

What do the colours in the diff result mean?

Green lines with a + prefix exist only in the modified version — they were added. Red lines with a - prefix exist only in the original — they were removed. Unprefixed lines are unchanged. When a line was edited rather than replaced, the old and new versions appear as a red/green pair with the specific changed words highlighted in a stronger shade inside each line, so you can spot a one-word correction in a long paragraph without re-reading the whole thing.

Can I compare documents, essays or config files?

Yes — anything that is plain text: essays, emails, contracts, source code, config files, JSON, CSV or Markdown, up to 3,000 lines per side. Formatted documents like Word files should be pasted as text; the formatting is dropped but the words compare cleanly. Line-based comparison works best when the text has natural line breaks, so for one long paragraph the word-level highlighting inside the modified line does the heavy lifting.

Can I use the diff checker to detect plagiarism?

A diff checker is not a plagiarism detector, but it is ideal for closely comparing two versions of the same document — a submitted essay against an earlier draft, a contract against the previous revision, or an edited article against the original. It highlights every insertion, deletion and change line by line, which is often more precise than a similarity score when you need to see exactly what was modified.

How do I copy or save the diff result?

Click Copy diff above the result panel to copy the comparison in unified diff format — each added line prefixed with + and each removed line with -. This is the same plain-text convention used by Git and code review tools, so the output pastes cleanly into an email, a document, an issue tracker or a code review comment, and anyone technical will read it without explanation. For a permanent record, paste it into a text file and save it alongside the documents you compared.

How do I compare two texts for differences online?

Paste the first version into the left panel and the second into the right — the comparison runs on its own, with no button to press and no file upload. Read the result from the top: green marks text that appears only in the second version, red marks text that appears only in the first, and unmarked lines are identical in both. Because the whole comparison happens inside your browser, there is no size limit imposed by a server and no copy of your text stored anywhere; closing the tab is all it takes to discard it.

Can I compare two strings or two lines rather than whole documents?

Yes, and short comparisons are where word-level highlighting is most useful. Paste one string into each panel and the tool marks the exact characters and words that differ instead of just reporting that the two lines are not equal. This is the quickest way to spot a transposed digit in a reference number, a trailing space that breaks a lookup, or a smart quote that has replaced a straight one — differences that are effectively invisible when you read the two strings side by side.

Does the tool measure text similarity as a percentage?

No — it reports the differences themselves rather than a similarity score, which is usually the more useful answer. A percentage tells you two documents are 94% alike but not which 6% changed, whereas the diff shows you every insertion and deletion so you can judge whether the changes are trivial or substantive. If the two texts are identical the result comes back empty, which is the unambiguous version of a 100% match.

Why does the diff show changes when the texts look the same?

Almost always because of invisible characters. Trailing spaces at the end of a line, a tab where the other version has spaces, non-breaking spaces pasted in from a web page, curly quotation marks pasted in from Word, or Windows line endings meeting Unix line endings all count as real differences even though they render identically. Running both versions through remove extra spaces before comparing normalises most of these and leaves only the edits you actually care about.