Compare Text Online

Compare two texts, code snippets, or local text files. Find added, removed, and edited lines with word- or character-level detail.

Original Text

Drop a text file here or paste text · 1 lines0 bytes · 0 characters

Modified Text

Drop a text file here or paste text · 1 lines0 bytes · 0 characters
Comparison options

Windows and Unix line endings are normalized for comparison. Trimming affects only line edges. “Ignore whitespace differences” removes all whitespace for comparison, including whitespace inside strings and code. Changing language affects highlighting only.

How to use this tool

Paste or type the original and modified versions, choose comparison options, and select Compare. Use the change controls to navigate differences, switch between side-by-side and unified views, or download a unified diff. Files are read locally and are not uploaded. Processing happens in your browser; entered values are not sent to a service.

Frequently asked questions

What kinds of text can I compare?

The comparison is language-independent and works with prose, source code, JSON, XML, logs, configuration files, and other plain text. Syntax highlighting is optional and does not change the comparison.

Are my text and files uploaded?

No. The diff runs in a browser worker. Local files are read in your browser and are not sent to a comparison service.

Can I compare Word, PDF, or spreadsheet files?

This tool compares text content only. It does not extract document internals from Word files, PDFs, spreadsheets, or images.

What is the file size limit?

Each input is limited to 2 MiB and 20,000 lines to keep comparisons responsive. Larger files should be split into smaller text sections.

Does the downloaded diff follow Git patch rules?

The download is a standard unified diff generated from the original inputs. Ignore settings affect only the on-page view; the export always includes the original text.