Text diff / compare
See what changed between two versions, from whole lines down to a single character.
0 / 100,000 code units
0 / 100,000 code units
Up to 1,500 lines per input. Processing stays in this page.
Compared locally. Text is never uploaded or saved by this tool.
How to compare two texts
- Paste the first version into Original text and the second into Revised text. Load example fills both with a small, public sample.
- Choose Words or Characters for emphasis within changed lines. Select Compare texts, or press ⌘ / Ctrl + Enter.
- Read − removed lines from the original and + added lines from the revision. Deletions have a strike-through; additions have an underline. Each side keeps its own line numbers.
- Use Auto for side by side on a wide screen and unified on a narrow screen, or select either layout. Copy either original input or a readable comparison transcript.
For example, Bring coffee for two. → Bring coffee for three. removes two and adds three. In Characters mode, 9:00 → 9:30 emphasizes only the changed digit. Added or removed blank lines count as changes too.
Whitespace, newlines, and Unicode
- Exact by default
- Spaces, tabs, case, blank lines, newline style, and the final newline all count. Show spaces / tabs displays a middle dot for a space and an arrow for a tab without changing either input.
- Explicit ignore options
- Ignore edge spaces / tabs ignores only leading and trailing ASCII spaces and tabs on each line. Ignore newline style equates LF, CRLF, and CR, while still detecting a missing final newline. Neither option rewrites the inputs.
- Unicode stays literal
- No case folding or Unicode normalization is applied:
éande + ◌́can differ. Character mode groups grapheme clusters with Intl.Segmenter when supported, and otherwise compares Unicode code points.
Every line ends with a cue: LF (Unix), CRLF (Windows), CR, or EOF for no final newline. Pasted newline styles are retained when comparing and copying, although textareas display them as line breaks. Typed line breaks use the browser's newline behavior. Selected control, bidirectional, and invisible characters are shown as ⟨U+XXXX⟩ in results. The input copy buttons retain the original characters.
What this text comparison does
Use it for prose, configuration snippets, logs, and source text. The comparison is textual: it does not parse, repair, reformat, execute, merge, or infer the meaning of your text. Adjacent removed and added lines are placed together by position for reading; that pairing does not identify moved or equivalent content. The comparison transcript is a review aid, not an applicable patch.
Each input is limited to 100,000 UTF-16 code units and 1,500 lines. Oversized pastes are rejected with the existing input left intact. A worker keeps calculations off the main browser thread, with a 600 ms computation budget, edit-count limits, and a two-second termination guard. If a comparison is too expensive, compare smaller excerpts. Some long or heavily changed lines use whole-line emphasis, with a visible notice, to stay within the detail budget. Clear all removes both inputs and the result.
Local processing and privacy
Your texts and comparison stay in this page's memory. This tool does not send them to servers, analytics, or logs, put them in URLs, or save them in browser storage. Clear all or leaving the page clears the tool's state. Copy writes only the chosen text to your clipboard, which your device or clipboard manager may retain. Loading the page still requests the site's files; read the site privacy details.
The comparison engine uses jsdiff. Its BSD license is included in the tool notices.
Related browser tools
- URL encode / decode — Encode text for URLs and decode percent-encoded strings.
- UUID generator / validator — Generate random UUIDs and check their format and version.
- Base64 encode / decode — Encode UTF-8 text as Base64 or Base64URL and decode it back.
- JWT explorer / creator — Inspect JWT claims and timestamps, create HS256 tokens, and check signatures locally.
- JSON formatter / validator — Pretty print, minify and validate JSON while preserving numbers and duplicate keys.
- Timestamp converter — Convert Unix seconds, milliseconds, and ISO dates with UTC and local timezone output.
- Text hash generator / comparison — Generate SHA-256, SHA-384 or SHA-512 text hashes and compare an expected hash.