Format messy SQL queries with proper indentation. Supports MySQL, PostgreSQL, SQLite, MS SQL, Oracle, BigQuery, and more.
Formatted SQL is dramatically easier to read, debug, and review. A long single-line SELECT with multiple joins is impenetrable; the same query with each clause on its own line, properly indented, makes the data flow obvious. This is critical for code review and onboarding new developers.
LIMIT clauseRETURNING clauseSTRUCT and ARRAY typesTOP instead of LIMITNo. It only formats the syntax — it does not connect to any database.
UPPERCASE is the traditional convention and aids visual parsing. Some modern style guides prefer lowercase. Both are valid — pick one and stay consistent.
Want more detail? Read How to Use SQL Formatter: Practical Guide and Best Practices.