Developer tool

SQL Formatter

Paste a SQL query and format common clauses, indentation and keyword casing locally.

Runs in your browser. No upload.

About this tool

SQL Formatter made simple.

The formatter recognizes common SQL clauses, quoted strings and comments while adding readable line breaks and indentation. It is a best-effort formatter, not a parser, syntax validator or database connection; review the output before running it.

Common questions

About SQL Formatter.

What does an SQL formatter do?

It adds line breaks and indentation to common SQL clauses and can normalize recognized SQL keyword casing.

Does this tool validate or run SQL?

No. It is a best-effort formatter, not a syntax validator, database connection or security checker. Review the output before use.