Loading…
Loading…
Compare two texts or code files side by side, with changed words highlighted. Ignore whitespace or case, and export a unified .diff patch that git apply accepts.
Also covers: Text comparison · Text comparer · Text difference checker
Paste text into both panes to compare them, or click Load sample.
Paste the original on the left and the changed version on the right, or drop or upload a file into each pane. Swap flips them if you pasted them the wrong way round. The diff updates as you type.
Removed lines are red and added lines are green, with the exact words that changed highlighted inside each line. Side by side lines the two versions up; Unified shows one column, like git diff.
Hide unchanged lines keeps 3 lines of context around each change and folds the rest; click a fold to open it. Ignore whitespace skips indentation and spacing changes, and Ignore case skips capitalization-only changes.
Copy or download the result as a standard unified .diff patch. It applies with git apply or patch, and it's the format code reviewers and issue trackers expect.
No. The comparison runs entirely in your browser, so you can diff config files, connection strings, contracts, or proprietary code without it leaving your machine.
All spaces and tabs inside each line, so re-indented code, reformatted SQL, or tabs converted to spaces don't show as changes. Line breaks still count, so a line split in two is still a change. The display and the patch always show your original text, not a normalized copy.
Yes. It's a standard unified diff with 3 lines of context, including the "No newline at end of file" marker when needed. Save it and run git apply changes.diff or patch original.txt changes.diff. With Ignore whitespace or Ignore case on, lines that differ only that way are left out of the patch, just like diff -w or -i.
Diffs work line by line: an edited line is a removed line plus an added line. When the two are similar, the changed words inside them are highlighted so you can see the actual edit. When they have little in common, the whole line is highlighted, because marking every word would just be noise.
Windows (CRLF) and Unix (LF) line endings are treated as equal, so a file saved on a different OS doesn't show as entirely changed. You still get a note that they differ. A missing newline at the very end of a file is a real difference to Git and other tools, so it's flagged and kept in the patch.
Count
Count words, characters, sentences, paragraphs, and lines as you type, with reading and speaking time. Check text against X, SEO title, and meta description limits.
Case
Convert text to UPPERCASE, lowercase, Title Case, Sentence case, camelCase, PascalCase, snake_case, kebab-case, and more, line by line.
Cleanup
Clean up messy text: remove extra spaces, blank lines, invisible characters, and HTML tags, straighten quotes, and rejoin hard-wrapped lines.
Lines
Delete repeated lines from a list and keep the original order. Choose case sensitivity, whether to ignore surrounding spaces, and whether to keep the first or last copy.
Lines
Delete blank lines from text, or collapse runs of blank lines down to one so paragraphs stay separated.
Whitespace
Collapse repeated spaces into one, trim spaces from the start and end of lines, or remove every space. Line breaks are kept.