Unminify SQL Online — Free SQL Formatter

Unminify compressed SQL. Restore readable formatting from minified queries, with all processing in your browser.

Loading…
SQL Unminification
Unminify SQL online.

Features

Restore readable formatting via sql-formatter.

Unminify SQL

Restore readable formatting via sql-formatter.

Basic example

Minified SQL

SELECT c.id, c.email, o.total, o.created_at FROM customers AS c INNER JOIN orders AS o ON o.customer_id = c.id WHERE c.active = TRUE AND o.status = 'completed' ORDER BY o.created_at DESC LIMIT 50;

Formatted SQL

SELECT c.id, c.email, o.total, o.created_at FROM customers AS c INNER JOIN orders AS o ON o.customer_id = c.id WHERE c.active = TRUE AND o.status = 'completed' ORDER BY o.created_at DESC LIMIT 50;

Options

SQL Dialect
Target dialect for beautify formatting (standard, PostgreSQL, MySQL, SQLite).
Keyword Case
Upper, lower or preserve keyword casing during beautify.
Indent Width
2 or 4 spaces for beautify and unminify output.

Dialect support

Beautify supports standard SQL, PostgreSQL, MySQL and SQLite dialects. Minify uses whitespace stripping. Edge cases in T-SQL or BigQuery are out of scope.

FAQ about unminifying SQL

Unminification

How does unminify work?

Uses sql-formatter to add line breaks and indentation.

Make minified code readable again to debug or review it. Unminify JavaScript, CSS, TypeScript, SCSS, LESS, SQL, YAML and other formats.