Compare Files Online — Free & Private

Drop two files in any combination — PDF, Word, TXT, Markdown or source code — and see every difference highlighted word by word. Everything runs in your browser; nothing is ever uploaded.

Local processing only — your files never leave your device.

No comparison yet. Paste or upload text in both fields below — results appear here automatically, and nothing is calculated until you do.

Precision:
View:

Compare your two texts

Original Text (A)
0 words

Modified Text (B)
0 words

Supported File Formats

PDF (.pdf)

Text-based PDFs are parsed with pdf.js page by page.

Word (.docx)

Microsoft Word documents are converted via mammoth.js.

Text & Code

TXT, MD, JSON, source code — loaded directly, no conversion.

Why Compare Files in the Browser?

Instant. No upload roundtrip — the diff appears as soon as the file is parsed.

Private. Sensitive contracts, NDAs and source code never leave your computer.

Free forever. No accounts, no quotas, no ads.

How SnapTextCompare works

Diff engine

Google's diff-match-patch (Apache 2.0), running in your browser. Character mode diffs raw characters; word and line modes encode tokens or lines first and diff those, then decode the result.

Similarity & importance

Similarity = 1 − Levenshtein / max(len). Importance weighs each change by category — money and dates score 90+, punctuation scores 3. Deterministic on any device.

Privacy

Files are read with the HTML5 File API and processed in your browser. No network request is ever made with your content — verifiable in the Network tab of your browser's DevTools.

PDF extraction uses pdf.js (Mozilla). Word extraction uses mammoth.js. UTF-8 with or without BOM is auto-detected; CRLF line endings are normalised to LF before diffing so cross-OS files don't appear entirely changed.

File Comparison FAQ

Common questions about comparing files online.

Yes. SnapTextCompare lets you compare files (PDF, Word, TXT, MD, code) directly in your browser — no signup, no upload, no fee.

PDF (.pdf), Word (.docx), plain text (.txt), Markdown (.md), and any source code file. Both files can be different formats.

No. Every comparison runs locally in your browser using pdf.js and mammoth.js — your files never leave your device.

Practical limit is around 10 MB per file since processing happens in-browser. Most documents and code files are far smaller than that.

Yes. Drop both PDFs into the tool and the extracted text is diffed word-by-word. For a dedicated PDF guide, see our compare PDF files page.