Code Diff
Compare two code snippets side by side with syntax highlighting.
Three steps to done
Drag and drop or click to browse
Runs in your browser, nothing uploaded
Get your file instantly
When to use this
Code review
Paste two versions of a function side by side to review what changed before approving a pull request.
Compare config files
Diff two configuration files to identify differences between environments or versions.
Spot regressions
Compare a working version to a broken version of a script to quickly isolate what changed.
Code diff tool with line numbers
Paste two code snippets and instantly see what changed. Green lines are additions, red lines are deletions, and unchanged lines are shown in context. Both side-by-side and unified views are available. Line numbers are shown on both sides so you can reference changes precisely.
The tool uses an LCS diff algorithm, the same technique used by Git. It compares line by line and produces a minimal diff that shows only the relevant changes without noise.
Everything runs in your browser. No code is uploaded or sent to a server. The language selector is provided for labeling purposes only and does not affect how the diff is computed.
Frequently Asked Questions
Related tools
All toolsCompress Image
Reduce image file size without losing quality. Supports PNG, JPG, and WEBP.
HEIC to JPG
Convert iPhone HEIC photos to JPG format instantly in your browser.
Resize Image
Resize images to exact dimensions with presets for Instagram, LinkedIn, YouTube, and more.
JPG to PNG
Convert JPG images to PNG format with transparency support.
3 free uses left today
Unlimited with Pro