Last updated ·Published ·By the WiserWork team

Text Diff Checker

Compare two texts and find differences line by line

Line-by-line comparison
Waiting for comparison...
Click "Compare Texts" to see differences...

Paste two versions of a document side by side and get a line-by-line report of what was added, removed and left alone, computed with a longest common subsequence match.

What is the Text Diff Checker?

Comparing two texts is really a search for the longest run of lines the two share in the same order. This checker builds that longest common subsequence with a dynamic programming table, filling a grid sized by one text against the other, then walking backward through it to decide for each line whether it survived, disappeared or is new. Because the alignment is computed rather than assumed, inserting a paragraph near the top does not shove every later line into the changed pile the way a naive position-by-position comparison would. The unit of comparison is a whole line, matched by exact string equality.

Key Features

  • Longest common subsequence alignment rather than position-by-position line matching
  • Counts of added, removed and unchanged lines above the report
  • Unified output with plus and minus prefixes and color coding
  • Swap button reverses which pane counts as the original
  • Clear All empties both panes and resets the report

Common Use Cases

  • Checking what an editor changed between two returned drafts of a chapter
  • Spotting the edited clause in a contract sent back for signature
  • Comparing two configuration files that behave differently on two machines
  • Verifying that a translated list still contains every original entry

How to Use the Text Diff Checker

  1. Paste the earlier version into the Original Text pane on the left.
  2. Paste the newer version into the Modified Text pane on the right.
  3. Click Compare Texts, since the report does not refresh on its own as you type.
  4. Read the counts above the output, then scan the plus and minus lines beneath them.
  5. Use Swap to flip the two panes, or Clear All to empty everything and start over.

Tips for Best Results

  • Matching is exact, so a trailing space or a changed capital marks the whole line different.
  • A reworded sentence appears as its old line removed and the new line added.
  • Break long paragraphs onto separate lines first, since a line is the smallest unit compared.
  • The table grows with both texts multiplied together, so very large documents feel slow.

Why Use WiserWork's Text Diff Checker?

A line-level diff is the fastest honest answer to the question of what changed, and it beats reading two documents in adjacent windows and trusting your eyes. This checker computes the real alignment instead of comparing line one against line one, so an inserted heading does not turn everything below it red. Both texts stay inside the page, which matters when the documents are a contract draft or an unreleased configuration file.

Who Uses the Text Diff Checker?

Writers and editors reconciling revisions, lawyers checking a returned markup against what they sent, and developers comparing two config files or log excerpts without setting up a repository. Translators and QA testers use it to confirm nothing was dropped between two versions of a list.

Frequently Asked Questions

Does the comparison run automatically?

No. Editing either pane leaves the previous report on screen until you click Compare Texts. The Swap button reruns the comparison as part of swapping.

What counts as a difference?

A whole line, compared by exact string equality. Differences in capitalization, punctuation or trailing whitespace make two otherwise similar lines register as one removal plus one addition.

Does it highlight the changed words inside a line?

No. The comparison is line-level only, so a rewritten line shows as the old version marked with a minus and the replacement marked with a plus, and you spot the changed words yourself.

What algorithm is behind it?

A longest common subsequence computed with a dynamic programming matrix over the lines of both texts, followed by a backward walk through that matrix that labels each line unchanged, added or removed.

How is the output ordered?

It follows the order of the merged document. Where a line was rewritten, the removed version appears first and the added version directly after it.

Can I compare code or markup?

Yes, and HTML or XML is safe to paste because angle brackets are escaped before display rather than rendered. Indentation is part of the line, so a reindented block reads as changed.

Is there a size limit?

No fixed cap, but the matrix holds one cell for every pair of lines across the two texts, so two very long documents use far more memory and time than two short ones.

Can I download or copy the report?

There is no export or copy button on this tool. Select the output with the mouse and copy it the usual way if you need it elsewhere.

What does the unchanged count mean?

It is the number of lines the algorithm matched in both texts in the same relative order. Added and removed count the lines unique to the modified and original panes.

Do blank lines matter?

Yes. An empty line is still a line, so adding or deleting one shows up in the report and shifts the counts.

Two documents that look identical rarely are. Running them through a real subsequence alignment turns a slow reading exercise into a short list of lines, and tells you exactly how many of them are genuinely new.

Found this useful? Share it