Developer
Text and Code Diff
Compare two texts line by line and see exactly what changed, down to the word.
Runs entirely in your browser. Nothing you paste is uploaded.
This runs entirely in your browser. Nothing you paste is sent to us or to anyone else.
How to use it
- Paste one version into "Original" and the other into "Changed"Order matters only for how the result reads: what is in Original is treated as the before, and what is in Changed as the after. Everything happens inside your browser β nothing is uploaded, so there is nothing for us to store, log or lose.
- Read the result as it updatesThere is no button to press. The differences highlight as soon as both boxes have text. The output recomputes every time you change the text or one of the options above it.
- Read additions and removals as a pairA changed line usually shows as one removal and one addition. That is what a line-based diff does, and it is why a reformatted file can look entirely rewritten when nothing meaningful changed.
- Check the notes before concluding anythingDifferences that are only whitespace or only line endings are called out. A file that came from Windows and one that came from Linux differ on every single line for a reason nobody cares about.
- Use it on anything textualCode, config, prose, JSON. Nothing is uploaded, which matters when the two things you are comparing are versions of a contract.
- Copy or download the resultThe buttons under the output put it on your clipboard or save it as a file, and each one says exactly what it will copy or download. Any note about something the tool changed or deliberately left alone is shown with the result rather than hidden.
About this tool
Paste two versions of a text or a file and see exactly what changed between them: which lines were added, which were removed, and which words inside a changed line differ.
It uses the Myers algorithm, the same approach behind `git diff`. That matters for the case people actually bring here: inserting one line at the top of a file should report one insertion, not "every line changed". A simpler line-by-line comparison reports the latter, which makes it useless for finding the line that actually moved.
Understanding the result
The counts are lines added, lines removed and lines identical in both. A line that was edited counts as one removal and one addition, because that is what a diff is β there is no separate "changed" operation.
When a removed line is immediately followed by an added one, the changed words within them are highlighted, so you can see that only one value differs rather than re-reading the whole line.
Line numbers are shown for each side independently, matching what your editor will show you.
Example
Input
alpha\nbeta\ngamma Β· alpha\nNEW\nbeta\ngammaOutput
alpha
+NEW
beta
gamma
+1 Β· β0 Β· 3 unchangedLimitations
- Comparison is line-based. Two files that differ only in how the lines are wrapped will show as heavily changed even though the words are identical.
- Windows and Unix line endings are treated as the same by default. Without that, a file saved on Windows differs from itself on every line β the most common false positive in any diff tool.
- Inputs over 5,000 lines are declined rather than truncated. The algorithm is quadratic in the worst case and would lock the tab; for files that size, `git diff` locally is the right tool.
- This compares text. It cannot compare binary files, images or documents such as .docx, which are archives rather than text.
Questions
Is my text uploaded anywhere?
No. The whole tool is JavaScript running on your device β there is no request to send. You can confirm it by opening your browser's network tab, or by disconnecting from the internet and using the page anyway.
Why does it say every line changed when the files look the same?
Almost always the indentation, or trailing whitespace on every line. Turn on "ignore indentation" to confirm β if the differences disappear, that was it. The tool says as much when it sees every line differ while the line counts match.
Why is an edited line shown as a removal and an addition?
Because that is what an edit is in diff terms. The tool pairs them and highlights the words that differ, so you get the readability of a "changed" line without pretending the underlying operation is anything other than a delete plus an insert.
Can I compare more than two versions?
Not here β this compares two. Three-way comparison is a merge, which needs a common ancestor and belongs in your version control system rather than in a web page.
Last updated 2026-08-16.
Related tools
- JSON Formatter and Validator
Format, minify and validate JSON entirely in your browser.
- Regex Tester
Test a regular expression against your text, with every match, group and a warning for catastrophic backtracking.
- Word, Character and Sentence Counter
Count words, characters, sentences and reading time β correctly for emoji and for scripts written without spaces.