Compare two texts or code snippets line by line and see exactly what was added, removed and left alone.
Put the original text in the left box and the changed text in the right box. Anything works: prose, JSON, SQL, configuration files, or a block of source code copied out of an editor.
Removed lines are highlighted in pink on the left, added lines in green on the right, and the counters above tell you how many lines changed in total before you read a single row.
Side by side is best for reviewing a rewrite, while unified reads like a patch and is easier to follow when the two versions are mostly identical with a few edits.
No. The comparison runs in your browser in JavaScript. Neither version is sent to a server, which makes the tool safe for code and configuration you would not paste into an online service.
It builds a longest common subsequence table over the lines of both inputs, then walks it to align matching lines. That produces a cleaner result than a naive line-by-line match when content is inserted in the middle.
It compares whole lines. For a changed line you see the old version marked as removed and the new one marked as added, which is how most code review tools present a modified line.
Yes. Any text works. For JSON, formatting both sides with the JSON formatter first usually gives a much more readable diff, because consistent indentation stops unrelated lines from appearing changed.
There is no hard limit, but the comparison uses a table proportional to the two inputs multiplied together, so very large files can get slow. It is built for snippets and files rather than entire repositories.
No. Windows carriage returns are normalised before comparing, so a file saved on Windows and one saved on macOS will not show every line as changed.
It shows exactly which lines two documents share, which is useful for spotting copied passages, but it compares only the two texts you paste. It does not search the web.
Yes, completely free with no sign-up, no watermark and no limit on how many comparisons you run.
Free online JSON formatter and validator. Format, minify and validate JSON with syntax highlighting and instant error detection.
Open ToolConvert text between uppercase, lowercase, title case, camelCase, snake_case, kebab-case, and more.
Open ToolCount words, characters, sentences, and paragraphs with reading time estimation.
Open Tool