Tutorial · Text Diff · 3 min read

How to Compare Two Texts Line by Line

Paste two versions of a file or message and see exactly which lines were added, removed or changed, without installing anything or leaving the browser.

Before you approve a config change or answer "what did you change", you want a line diff. The tool aligns the two texts, marks removed lines with a minus and added lines with a plus, and leaves unchanged context in place so the change reads naturally.

What you'll learn

  • Produce a unified-style diff of two texts
  • Read added, removed and unchanged lines
  • Copy the diff into a review or ticket

Step by step

  1. Paste the original

    Open the Text Diff Checker and paste the earlier version into Original.

  2. Paste the changed version

    Put the new text into Changed. Trailing whitespace counts as a difference, which is often exactly the bug.

  3. Click Compare

    Lines are colour-coded: red with a minus for removed, green with a plus for added, muted for unchanged.

      server {
        listen 80;
    +   listen 443 ssl;
        server_name example.com;
    -   proxy_buffering on;
      }
  4. Copy the diff

    Copy Diff produces the plus and minus text for pasting anywhere monospace text is readable.

Open the tool with this example Runs in your browser. Nothing you paste is uploaded.

Common problems

Everything is marked as changed

Line endings differ (Windows CRLF against Unix LF) or indentation was converted between tabs and spaces. Normalise one side first.

FAQ

Does it diff words within a line?

No, it works per line, which is the right granularity for configs and logs. Use JSON Diff for structured data.