SQL Formatter

Format messy SQL queries into readable, indented code for many dialects. Free, no sign-up, runs in your browser.

Loading tool…

About this tool

Paste a query and choose the database dialect. Keywords are uppercased and clauses, joins and subqueries are indented.

How to use it

  1. Enter or paste your values in the fields above.
  2. The result updates as you type.
  3. Use the Copy button to copy the result.

Frequently asked questions

Which dialects are supported?

Standard SQL, PostgreSQL, MySQL, MariaDB, SQLite, SQL Server (T-SQL), BigQuery, Snowflake and more.

Let’s talk

Need a team to build it?

We build the software behind tools like this: web apps, APIs, SaaS products and AI features.