SQL Query Formatter

Format and beautify SQL queries online. Standardize SQL syntax for PostgreSQL, MySQL, and SQLite with UPPERCASE keywords. Free SQL formatter.

About this tool

SQL Query Formatter beautifies and standardizes complex SQL queries for PostgreSQL, MySQL, SQLite, and ClickHouse with custom indentation and keyword casing.

How to use

  1. Paste your unformatted or minified SQL query.
  2. Toggle UPPERCASE keywords and choose indentation spacing (2 or 4 spaces).
  3. Copy the beautified SQL query.

FAQ

What SQL dialects are supported?

Supports ANSI SQL, PostgreSQL, MySQL, SQLite, BigQuery, and MariaDB queries.

Does it format subqueries and JOINs?

Yes, clauses like LEFT JOIN, GROUP BY, and HAVING are cleanly aligned.

What does SQL Query Formatter do?

SQL Query Formatter beautifies and standardizes complex SQL queries for PostgreSQL, MySQL, SQLite, and ClickHouse with custom indentation and keyword casing.

How do I use SQL Query Formatter?

Open the SQL Query Formatter tool, then paste your unformatted or minified SQL query.

Related tools