SQL Diff Online
A simpler, faster way to diff two SQL files without the full schema comparison features.
Paste two SQL schemas and see exactly what changed. Tables added, columns dropped, types narrowed, indexes missing — every difference highlighted with a semantic diff that understands SQL structure, not just text.
Supports PostgreSQL, MySQL, SQLite, SQL Server, and Oracle. No data leaves your browser.
Text diffs break when SQL is reformatted. SchemaLens understands structure.
See every table, column, and constraint compared in a clean visual layout. Green for additions, red for removals, yellow for modifications. No more scrolling through thousand-line text diffs.
Automatically flags dropped tables, removed columns, NOT NULL without defaults, type narrowing, and missing indexes. Know what's dangerous before you deploy.
PostgreSQL, MySQL, MariaDB, SQLite, SQL Server, and Oracle. Our custom parser understands each dialect's unique syntax and compares them accurately.
Every comparison gets a 0–100 risk score based on the severity of changes. Low-risk diffs get a green light. High-risk diffs demand a second review.
Get ready-to-run ALTER TABLE scripts generated from the comparison. Copy, paste into your migration tool, and deploy with confidence.
Share any schema comparison with your team via a URL. Perfect for code reviews, architecture decisions, and compliance audits.
| Element | Detected | In Migration |
|---|---|---|
| Tables (added/removed) | ✅ Yes | ✅ Yes |
| Columns (added/removed/modified) | ✅ Yes | ✅ Yes |
| Data types & defaults | ✅ Yes | ✅ Yes |
| Primary & Foreign Keys | ✅ Yes | ✅ Yes |
| Indexes | ✅ Yes | ✅ Yes |
| CHECK & UNIQUE Constraints | ✅ Yes | ✅ Yes |
| Triggers | ✅ Yes | ✅ Yes |
| Views | ✅ Yes | ✅ Yes |
| Functions & Procedures | ✅ Yes | ✅ Yes |
Run pg_dump --schema-only or export from your ORM for both the old and new schema versions.
Paste schema A and schema B into SchemaLens. Choose your SQL dialect. Click Compare.
Scan the visual diff for breaking changes. Check the risk score. Review each table's changes in detail.
Copy the generated ALTER TABLE scripts. Share the diff URL with your team. Deploy with confidence.
A simpler, faster way to diff two SQL files without the full schema comparison features.
Generate ALTER TABLE scripts from any schema comparison. Ready to run in your migration framework.
Learn what SchemaLens flags as breaking — and why catching them early saves production incidents.
Stop guessing what changed between schema versions. Paste both schemas into SchemaLens and get a semantic diff with breaking change detection and ready-to-run migration SQL.
Compare Schemas NowNo signup required. No data leaves your browser.