Support

Runs in your browser· your SQL never leaves your device

Input
Output

Format SQL queries for readability and code review

Format and beautify SQL queries for readability. Indents keywords, aligns clauses, and standardises capitalisation. Useful for code reviews, documentation, and debugging complex queries involving joins, subqueries, and window functions.

Frequently Asked Questions

What SQL dialects does the formatter support?
Pick standard SQL (auto) or the PostgreSQL, MySQL, BigQuery, Snowflake, Spark SQL or DuckDB dialect so dialect-specific syntax is recognised.
Does formatting change query logic?
No. The formatter only changes whitespace and capitalisation — it never alters keywords, table names, column names, or query logic.
Can I use this for Spark SQL or Snowflake queries?
Yes. Spark SQL and Snowflake SQL are both based on standard SQL and format correctly with this tool.
Is my SQL sent to a server?
No. Formatting is done entirely client-side in your browser.
Is there a Snowflake or BigQuery SQL formatter?
Yes. Choose Snowflake or BigQuery in the dialect list and the formatter handles their syntax. MySQL, PostgreSQL, Spark SQL and DuckDB are also available.

Found this useful? Hexabench is free and ad-free. If it saved you time, you can support it.

Buy me a coffee →