Text & JSON Diff Checker

Compare two texts line by line, or diff JSON structurally — with inline highlights, right in your browser.

The text and JSON you enter are compared locally in your browser and never sent to a server.

Comparison result

Press "Compare" to see the result

How to compare

  1. Choose Text or JSON mode.
  2. Paste the "before" and "after" content into the two boxes.
  3. Click "Compare" to see how many lines or entries were added, removed, changed or left unchanged, with the full diff below.
  4. Use "Swap" to flip the two sides, and "Copy diff summary" to copy a compact summary of the differences.

How the text diff works

Text is compared line by line; line-ending style alone (LF, CRLF or CR) never counts as a difference. A run of removed and added lines is paired up and shown as changed lines, and within each pair only the characters that actually changed are highlighted — the common prefix and suffix are left plain. For very long lines (over 20,000 characters) the inline highlight is skipped and the whole line is shown as changed.

Comparison works per character (code point), so emoji and non-ASCII text are never split apart.

JSON comparison rules

  • Object keys are compared without regard to order.
  • Arrays are compared index by index, so reordering elements shows up as changes at each position — element moves are not detected.
  • Differences are reported with paths such as $.user.name or $.items[0].
  • A value that changes type — for example from a number to a string — is reported as "Type changed", distinct from a plain value change.
  • Below the structural diff you also get a line-by-line diff of both documents with their keys sorted, so nothing hides in formatting differences.

Syntax errors are reported with the exact line and column plus a hint for common mistakes such as trailing commas. Nesting deeper than 20 levels is compared as a whole, and differences beyond 200 entries are omitted — both cases are clearly flagged.

Input limits

Each side of a text comparison accepts up to 200,000 characters and 2,000 lines. Inputs beyond the limit are not compared; you get an error message instead. For large files, pasting only the sections that likely changed is the fastest way to review them.

Privacy

Comparisons run entirely in your browser. Your texts, JSON documents and the diff results are never sent to a server, so you can safely paste configuration files or data that contain sensitive information.

FAQ

Is my input sent to a server?

No. Text and JSON comparisons run entirely in your browser. Neither your input nor the comparison result is ever uploaded — you can confirm this in the developer tools' network tab.

Does JSON key order matter?

No. Object keys are compared regardless of order, so two JSON documents that differ only in key order show "No structural differences." Arrays, on the other hand, are compared index by index, so reordered elements appear as changes at each position — moves are not detected.

What are the input limits?

Each side of a text comparison can be up to 200,000 characters and 2,000 lines. Larger inputs are rejected with an error message; paste only the parts that changed for the fastest comparison.

Can I copy the result?

Yes. "Copy diff summary" copies a compact text summary of the differences — matching, added, removed and changed entries — ready to paste into a ticket or pull request.

Related tools

Days Calculator

Calculate the number of days between two dates, or the date N days from now.

Age Calculator

Calculate exact age from a date of birth, including days lived and next birthday.

Business Days Calculator

Count business days excluding weekends and Japanese national holidays.

Character Counter

Count characters, lines, paragraphs and bytes of text in real time.

PDF Tools

Merge, extract and rotate PDF pages locally in your browser.

Markdown Editor

Write Markdown with live preview, HTML copy and .md download.

Scientific Calculator

Trigonometry, logarithms, exponents, factorials, history and memory.

Unit Converter

Convert length, weight, area, volume, temperature and data size.

Timestamp Converter

Convert between Unix timestamps, ISO 8601 and local date-times.

Percentage Calculator

Percentages, increase/decrease rates, discounts and reverse calculation.

Image Compressor

Compress JPEG, PNG and WebP images in bulk, entirely in your browser.

Image Converter

Convert between HEIC, JPEG, PNG, WebP and more without uploading files.

QR Code Generator

Create QR codes for URLs, text and Wi-Fi credentials in your browser.

Color Palette Extractor

Extract color palettes from images and copy them as CSS variables.

Hash Calculator

Compute and verify MD5, SHA-256 and other hashes for text and files.

Password Generator

Generate strong passwords, passphrases and PINs locally.

HMAC Checker

Compute HMAC signatures and verify webhook signatures in your browser.

Web Page Snapshot

Save the current page as a single self-contained HTML file.

Clipboard Cleaner

Clean invisible characters, extra line breaks and width inconsistencies.

Speed Test

Measure download/upload speed and ping in your browser.

Network Diagnosis

Check connectivity, DNS, IPv6 and the node you are connected through.

JSON Formatter

Format, validate and minify JSON with precise error locations.

URL Encoder / Decoder

Encode and decode URLs and query strings, including non-ASCII text.

Regex Tester

Test regular expressions with live matches, groups and replacement.

Line of Code Counter

Count total, blank, comment and code lines of pasted source code.

DNS Lookup

Query DNS records (A, AAAA, MX, TXT and more) with TTLs, DNSSEC and ASN hints.

CSV Checker & Converter

Check CSV/TSV structure, detect encoding (UTF-8, BOM, Shift_JIS) and convert to JSON.