📄 Diff Checker & Text Diff
Compare two texts side by side. Additions, deletions, and modifications are highlighted line by line with word-level granularity.
How to Use This Diff Checker
- Paste the baseline into the left panel — the version you want to treat as "before".
- Paste the changed text into the right panel. Both panels stay in your browser; nothing is uploaded.
- Click Compare. The tool runs a longest-common-subsequence diff over the two inputs.
- Read the result side by side. Content only on the left is a deletion, only on the right is an addition, and lines that changed on both sides are shown as modified with the changed words highlighted.
- Swap or Clear to flip the comparison direction or start a fresh one. The counter next to the buttons reports how many lines were added, removed and changed.
What Gets Highlighted
| Marker | Meaning | Typical cause |
|---|---|---|
| Removed line | Present on the left only | Deleted config key, dropped log line, removed paragraph |
| Added line | Present on the right only | New environment variable, extra import, appended row |
| Modified line | Both sides, different content | Changed value, reworded sentence, bumped version string |
| Unchanged | Identical on both sides | Context — kept visible so you can read the diff in place |
Because the comparison is word-granular inside changed lines, a single edited number or variable name is obvious instead of being buried in a redrawn line.
What Developers Actually Use It For
- Config drift — compare a working
.env, nginx block ordocker-compose.ymlagainst the version on another machine. - Log comparison — diff two runs to spot the one line where behaviour diverges.
- Reviewing pasted code — a colleague drops a snippet in chat; compare it against your local copy before committing.
- API response diffing — paste the pretty-printed JSON from two responses and see exactly which field changed.
- Prose and documentation — track edits between two drafts without a word processor's revision marks.
Diff Checker vs. Git Diff
git diff is the right tool inside a repository: it knows about revisions, staged changes and rename detection, and it emits a unified patch you can pipe into git apply. This page solves the other half of the problem — two blocks of text that were never in version control, or that live on two different machines. Paste both sides, get a side-by-side visual diff, and nothing leaves your machine.
❓ Frequently Asked Questions
What is a diff checker?
A diff checker compares two pieces of text and marks exactly what changed. Lines or words that appear only in the original are marked as deletions, lines that appear only in the new version are additions, and lines that changed on both sides are marked as modified with the changed words highlighted.
Is this text diff tool free and private?
Yes. The comparison runs entirely in your browser using JavaScript, there is no sign-up, and the text you paste is never sent to a server.
How is this different from git diff?
git diff runs against a repository and its revision history and outputs a unified patch format aimed at git apply. This online diff checker compares two arbitrary blocks of text you paste in, so it works for config files, logs, prose, CSV exports and JSON that were never in version control — and it renders the result side by side rather than as +/- lines.
Can I compare JSON or code, not just plain text?
Yes. The tool is plain-text aware, so any UTF-8 text works: JSON, YAML, SQL, source code, CSV, and prose. It does not parse or re-format your input, so what you paste is what gets compared.
Is Text Diff free to use?
Yes, Text Diff is completely free to use. No sign-up required, no usage limits.
Does Text Diff require an internet connection?
No. Text Diff runs entirely client-side in your browser — there is no server component and the text you paste is never sent anywhere. Once the page has loaded you can keep comparing with your network disconnected.
Related Free Tools
- JSON Formatter & Validator — format, validate and tree-view JSON before comparing it.
- Regex Tester — test a pattern against the lines you just diffed.
- Base64 Encoder and Base64 Decoder — decode an opaque blob so the diff is readable.
- Hash Generator — check two files are byte-identical before you spend time diffing them.
- Code & IDE Tools — more tools for comparing and formatting code.