SQL Formatter & Beautifier Online
Format and beautify SQL queries for MySQL, PostgreSQL, SQL Server, SQLite, Oracle and BigQuery, or minify SQL to one line. Free online SQL formatter.
How to use
- Paste your query.
- Pick the SQL dialect, indentation and keyword case.
- Click Format (or Minify) and copy the result.
Frequently asked questions
Which databases are supported?
MySQL, MariaDB, PostgreSQL, SQL Server (T-SQL), SQLite, Oracle PL/SQL, BigQuery and standard SQL.
Does minify keep string literals intact?
Yes. Quoted strings are preserved and comments are removed.
Is my query sent to a server?
No. Formatting runs in your browser.