SQL Formatter
Format a conservative SQL token subset while preserving literals and comments.
SQL Formatter workspace
Up to 200,000 input characters, depth 40 and 20,000 JSON nodes. Processing stays on this device; no input is stored. Use an example to inspect the accepted input structure.
Enter input or use the example.
How to use SQL Formatter
Paste SQL and select keyword case and indentation. Source is formatted as text and never executed.
Supported workflow and acceptance requirements
Token-aware SQL formatter preserving quoted strings, identifiers and comments; options keyword case/indent; does not execute queries.
Limits and local processing
Supports standard doubled quotes, common quoted identifiers, nested comments and PostgreSQL dollar strings. Backslash escapes are rejected as dialect dependent; this is a lexer, not a SQL syntax validator. Input is processed on this device without uploads. Browser workers and Web Crypto are required for the applicable tools; clipboard access depends on browser support.