About the SQL Formatter
Paste a messy SQL query and get it neatly formatted with consistent indentation and uppercased keywords. Choose your dialect — standard SQL, PostgreSQL, MySQL, SQLite, MariaDB or BigQuery — for accurate formatting.
Formatting runs entirely in your browser, so your queries are never uploaded. Readable SQL is easier to review, debug and share.
Features
- Beautify and indent SQL queries
- Multiple dialects supported
- Uppercases keywords for readability
- Copy the formatted query in one click
- Runs entirely in your browser
- Free with no sign-up and privacy-friendly
How to format SQL
- Select your SQL dialect.
- Paste your query into the box.
- Read the neatly formatted output.
- Click Copy to grab the formatted SQL.
Frequently asked questions
Which SQL dialects are supported?
Standard SQL, PostgreSQL, MySQL, SQLite, MariaDB and BigQuery.
Does it change my query's meaning?
No. Formatting only adjusts whitespace and keyword casing; the query logic is unchanged.
Is my query uploaded?
No. Formatting happens entirely in your browser.
Is it free?
Yes, completely free with no sign-up.