SQL Diff Tool
Paste two SQL scripts and see exactly what changed — added, removed and modified lines, side by side. Free, no signup, and your SQL never leaves your browser.
To compare two SQL scripts online, paste the original into the left pane and the changed version into the right. SQL Diff Tool highlights added, removed and changed lines side by side, using the Myers diff algorithm git uses. It works with any dialect (MySQL, PostgreSQL, SQL Server, SQLite), is free, and nothing leaves your browser.
Private by design
Script comparison runs entirely in your browser. Nothing is uploaded, nothing is stored, and it works offline once the page has loaded.
Instant results
A Myers diff — the same algorithm git uses — compares thousands of lines in milliseconds as you type. No upload, no queue, no waiting.
Scripts or databases
Diff SQL text for migrations and schema reviews, or compare two SQLite .db files table by table to find changed rows.
Need to compare two SQLite databases?
Upload two .db files and get a table-by-table breakdown of added, removed and modified rows, plus schema differences. Files up to 50MB are compared free in your browser and never uploaded. Larger files, up to 200MB and 500,000 rows per table, are compared on our servers with a paid account.
Compare SQLite databasesHow to compare two SQL scripts online
- Paste both sides. Put the original script in the left pane and the changed version in the right.
- Read the highlights. Removed lines show on the left, added lines on the right. The diff uses the Myers algorithm git uses and updates as you type.
- Cut formatting noise. Enable Ignore whitespace or Ignore case when indentation or keyword casing is the only difference.
- Stay private. Script diffs run in your browser — nothing is uploaded. For SQLite .db files, use the database compare (free up to 50MB / 200,000 rows per table).
Frequently asked questions
Is SQL Diff Tool free, and do my SQL scripts leave my browser?+
Yes for text diffs: paste two scripts or queries and they are compared locally in your browser — free, no signup, nothing uploaded. SQLite schema text diffs work the same way. Free .db file compares stay in the browser up to 50MB / 200,000 rows per table; larger files use a paid server compare.
Is my SQL uploaded to a server?+
No. The text comparison happens entirely in your browser using JavaScript. Your SQL never leaves your device, which makes the tool safe to use with production schemas and queries.
What is the difference between this and sqldiff?+
sqldiff is the official SQLite command-line utility that compares two .db database files and emits the SQL needed to transform one into the other. This tool compares SQL text — scripts, schemas, migrations and queries — in the browser, with no install. If you want to compare actual .db files here, use the database comparison feature.
Can SQL Diff Tool compare SQLite databases, not just SQL text?+
Yes. On /sqlite-diff you can paste two .schema exports or upload two .db files for a table-by-table row and schema diff. Schema paste is free in-browser. .db compares are free up to 50MB and 200,000 rows per table; larger files need a paid account.
Does it work with MySQL, PostgreSQL and SQL Server?+
Yes for script comparison. The diff is dialect-agnostic, so it works with MySQL, PostgreSQL, SQL Server, Oracle, SQLite or any other SQL text — including migration files and stored procedures.
How large a SQL file can it compare?+
Two scripts with up to 60,000 lines between them get a full line-by-line diff. In our tests, two 5,000-line schema dumps diff in about 2 milliseconds and two 25,000-line dumps in about 10 milliseconds. Between 60,000 and 300,000 lines the comparison switches to a coarser block-level diff so your browser stays responsive. Above 300,000 lines it reports accurate counts of added and removed lines instead of a line-by-line view.
How large a database can I compare?+
Free: .db files up to 50MB, compared in your browser with nothing uploaded, and up to 200,000 rows per table; every difference within those rows is reported. Paid plans: files up to 200MB and up to 500,000 rows per table, compared on our servers. Every row is compared, up to 50,000 differences per table are sent to your screen, and the complete result can be downloaded. In one of our tests, two 181MB databases with 323,625 rows each were compared in about 14 seconds, not counting upload time. Speed depends heavily on how wide the rows are.
How is SQL Diff Tool different from sqlformat.io, Aiven SQL Compare, or Text Compare?+
SQL Diff Tool compares SQL scripts side by side in your browser for free, with nothing uploaded. Unlike many online SQL compare tools that only diff text, it also compares SQLite .db files table-by-table (free up to 50MB and 200,000 rows per table) and supports MySQL and schema-focused pages. Paid plans cover larger .db files on our servers.
What's the best free online SQL diff checker for MySQL, PostgreSQL, and SQL Server?+
SQL Diff Tool works with any dialect (MySQL, PostgreSQL, SQL Server, SQLite). Paste the original into the left pane and the changed version into the right to see added, removed, and changed lines. Ignore whitespace and Ignore case options help when only formatting differs. Free for script and query diffs with nothing uploaded.
What is a free online SQL diff tool?+
A free online SQL diff tool lets you paste two SQL scripts or queries and see every added, removed and changed line side by side in the browser. SQL Diff Tool does that with a Myers diff, works with any dialect (MySQL, PostgreSQL, SQL Server, SQLite), needs no signup, and uploads nothing for text compares. It can also compare two SQLite .db files table by table (free up to 50MB and 200,000 rows per table; larger files need a paid account).
Stay updated
Occasional SQL tips and new tools. No spam, unsubscribe anytime.