Text Diff Checker — Compare Two Texts

Compare original and changed text line by line. Inspect additions, removals, line numbers and unchanged content, then copy or download the comparison.

◈ Processed in your browser · inputs are not saved

Line endings are normalized; other whitespace is significant.

Inputs stay in page memory. Only your theme preference is saved.

How it works

Place the old version on the left and the new version on the right, then compare. The result uses a longest-common-subsequence line comparison. Added lines show +, removed lines show − and unchanged lines show = in the table. Old and new line numbers help locate each change. Downloaded text uses a prefix on each line; it is a readable comparison, not a unified patch file.

Limits and behavior

Windows and old Mac line endings are normalized to line feeds for comparison. Spaces, tabs and a final newline are otherwise significant. Empty text is supported. Repeated lines may have several equally valid alignments. The tool selects one consistent alignment; it does not compare syntax trees or detect moved blocks. Limits are 1,500 lines per side and 1,000,000 line pairs.

Example

Changing const answer = 41; to const answer = 42; produces one removal and one addition. A trailing blank line appears separately. Each input is limited to 200,000 characters.

Assumptions and limitations

Start with Load example to see the expected input shape. Replace the example with your own text and choose the relevant operation. Editing an input invalidates the previous output so an old result cannot be copied as if it were current. Copy and download buttons become available after a successful run. Clear removes the visible inputs and output from the page. Limits keep small development tasks responsive; use a local editor or dedicated command-line utility for very large files. A successful transformation does not validate your application logic or make untrusted data safe to execute.

Sources

Lecture notes · Longest common subsequence

Frequently asked questions

Are pasted inputs saved or uploaded?

No. These tools process input in page memory. Only the selected display theme is stored. Reloading or changing language resets inputs. Your browser may independently offer form restoration.

Can I use the tools without signing in?

Yes. No account, API key or installation is required. JavaScript must be enabled. Each tool provides example input and a local output download.

Why did my previous output disappear?

Editing an input marks the old result as stale. Run the tool again before copying or downloading. This avoids mixing an earlier result with changed input.