How to use it
- 1
Paste SQL and choose the keyword casing.
- 2
Choose two- or four-space indentation and run the formatter.
- 3
Review any dialect warnings and copy the result.
What the tool can do
- Common SELECT, INSERT, UPDATE, DELETE, WITH, UNION, JOIN, ordering, and grouping clauses.
- Strings with escaped quotes, line and block comments, and quoted identifiers.
- Nested subqueries with bounded depth and readable indentation.
- Uppercase, lowercase, or preserved keyword casing.
Common use cases
- Preparing a query for code review.
- Reading SQL copied from logs or migrations.
- Normalizing an example for documentation or an issue.
How it works inside
Input is limited to 500,000 characters, 20,000 tokens, and depth 64.
The formatter does not connect to a database or send SQL to the WebDiag backend.
Questions and answers
Can it confirm that the query will run?
No. That requires the target database parser and schema, or a controlled test database. This tool only checks bounded lexical structure and delimiters.
Is the SQL uploaded?
No. Tokenization and formatting run locally in your browser.
