Skip to content
Marvin's Toolbox.

Search tools

Type to filter all tools

Text Diff

Compare two texts and see every added, removed and changed line highlighted, side by side or inline, with the changed words marked within each line. Ignore case, whitespace or blank lines, read a summary of how much changed, and export the result as a unified diff.

Everything runs locally in your browser. Your data never leaves your device.

Paste text into both panes to see the differences highlighted here.

Next steps

Send this tool's output straight into another tool.

Convert text into every case at once: title case in the APA, AP, Chicago, MLA, Bluebook, AMA and NYT styles, sentence case, upper, lower, camelCase, snake_case, kebab-case and more, each with its own copy button.

Count words, characters, sentences, paragraphs, lines and more as you type, with estimated reading and speaking time.

Remove duplicate lines from a list or text, keeping the first occurrence. Optionally ignore case and whitespace, or drop blank lines too.

Replace text in two modes: plain find and replace all, or regular expressions with flag controls and capture group references like $1.

Compare two texts and see every added, removed and changed line highlighted, side by side or inline, with the changed words marked within each line. Ignore case, whitespace or blank lines, read a summary of how much changed, and export the result as a unified diff.

Paste a UUID to see what it carries: version, variant, and for time-based versions the exact timestamp, clock sequence and node. Also shows the raw bytes, the 128-bit integer and the URN form.

Decode Base64 to text or encode text to Base64. Paste into the top box, read the result below, and flip the direction with one click. Handles Unicode correctly and reads URL-safe Base64 too.

Sort the lines of a text alphabetically, naturally, by length, by numeric value or shuffled. Reverse the order with a switch, and optionally trim lines, drop blank lines and remove duplicates in the same pass.

Convert a color between HEX, RGB, HSL, HSV, HWB, CMYK, OKLCH and OKLAB. Type into any field and the others update as you go, or pick the color visually. Reads CSS color syntax and keeps alpha where the format supports it.

Check two colors against the WCAG contrast rules. Type or pick a text and a background color, read the contrast ratio, see which AA and AAA checks pass, preview real text at the sizes WCAG distinguishes, and get suggested fixes when a check fails.

Create a QR code for text, a link, an email, a phone number, an SMS, Wi-Fi access or a contact card. Set the error correction level, size, margin and colors, then download it as PNG or SVG or copy it straight to the clipboard.

Paste a cron expression and get a plain English explanation, a field by field breakdown and the next times it would run, in your local timezone or UTC. Reads five field crontab syntax, six fields with seconds, names like MON and macros like @daily.

Work out an IPv4 or IPv6 network from an address with a prefix or netmask: network and broadcast addresses, usable host range, subnet mask, wildcard mask and address type. Adjust the prefix with a slider, read the binary breakdown, and split the network into smaller subnets.

About the Text Diff

This tool compares two pieces of text and shows exactly what changed between them. Paste the original version on one side and the changed version on the other, and every added, removed and modified line lights up, with the changed words marked inside each line.

Read the result side by side or as a single inline list, and check the summary to see how many lines were added, removed or modified and how much of the text changed overall. Long unchanged stretches fold away so the differences stay in view.

What you can do

  • Compare two texts line by line with the differences highlighted.
  • See the changed words marked inside each modified line.
  • Switch between a side by side view and an inline view.
  • Ignore case, whitespace or blank lines while comparing.
  • See how many lines were added, removed and modified.
  • Copy the result as a unified diff or download it as a patch file.

How to use the Text Diff

  1. 1Paste the original text into the left pane and the changed text into the right pane.
  2. 2Pick the split or inline layout, whichever reads better for your texts.
  3. 3Toggle the compare options to ignore case, whitespace or blank lines.
  4. 4Read the highlighted differences and the change summary above them.
  5. 5Copy the unified diff or download it as a .patch file to share the changes.

How the differences are matched

The comparison works line by line, using the same algorithm code review tools and version control systems use. When a block of lines is replaced by another block, the lines are paired up and compared word by word, so a small edit inside a long line shows as a highlight on the changed words rather than a fully red and fully green line.

Line numbers on each side always refer to the original texts, so you can find a change in your source even when the compare options hide some differences.

For two JSON documents the JSON Diff is usually the better fit. It compares the parsed structure instead of lines, so formatting and key order stop counting as changes.

The compare options

Ignore case treats lines that differ only in upper or lower case as equal. Ignore whitespace trims each line and collapses runs of spaces and tabs, so indentation and alignment changes stop counting as differences. Ignore blank lines leaves empty lines out of the comparison entirely. The panes keep your text exactly as you pasted it, the options only change what counts as a difference.

Unified diff export

The copy and download actions give you the result in unified diff format, the plain text form used by git diff and the patch command. It reflects the comparison you see, so differences hidden by the compare options are not included.

Decode Base64 to text or encode text to Base64. Paste into the top box, read the result below, and flip the direction with one click. Handles Unicode correctly and reads URL-safe Base64 too.

Remove duplicate lines from a list or text, keeping the first occurrence. Optionally ignore case and whitespace, or drop blank lines too.

Replace text in two modes: plain find and replace all, or regular expressions with flag controls and capture group references like $1.

Generate placeholder text: pick how many words, sentences or paragraphs you need, optionally starting with the classic Lorem ipsum opening, and copy the result.

Sort the lines of a text alphabetically, naturally, by length, by numeric value or shuffled. Reverse the order with a switch, and optionally trim lines, drop blank lines and remove duplicates in the same pass.

See what your clipboard really holds. One press lists every format on it, from plain text and HTML to Excel tables and images, each with its type, size and a preview. Pasting works too, and can reveal even more formats.