Public Tools SQL Formatter
Public Tools SQL Formatter is a free web tool that adjusts whitespace and keyword casing in SQL queries.
What Public Tools SQL Formatter is
Public Tools SQL Formatter is a free web tool that adjusts whitespace and keyword casing in SQL queries. It supports 20 dialects, including Standard SQL, PostgreSQL, MySQL, MariaDB, SQLite, SQL Server, Oracle PL/SQL, BigQuery, Snowflake, Redshift, Spark, Hive, Trino, DuckDB, ClickHouse, Db2, N1QL, SingleStore, and TiDB. You can choose uppercase, lowercase, or as-typed keyword casing, with two-space, four-space, or tab indentation. Semicolon-separated statements are formatted in sequence, with a blank line between them.
The page says the formatter runs in the browser and makes no network requests after loading, so queries stay on your machine; you can disconnect and continue using it. For an unbalanced parenthesis or unclosed quote, it reports the line and column. It does not verify query correctness, interpret your schema, optimize SQL, or lint it. Stored procedure bodies and vendor-specific scripting blocks are known weak spots. No sign-up or email address is required, and the free plan has no query-length or daily limit.
Good
- Supports 20 SQL dialects.
- Offers three casing and three indentation options.
- Can be used offline after loading.
- Free plan has no query-length or daily limit.
Watch out
- Does not validate query correctness.
- Does not optimize or lint SQL.
- Stored procedures and vendor-specific scripting blocks are weak spots.
Who it suits
This formatter suits people working with SQL queries or migrations who want to clean up formatting before copying the result into an editor. It is not a query validator or optimizer.
Verdict
Public Tools SQL Formatter is a focused option for changing SQL layout and keyword casing across many dialects. Its stated limits mean it should not be used to check whether a query is correct or optimized.
Plans and prices
From Public Tools SQL Formatter's own pricing page, checked 8 Oct 2001.
| Plan | Price | What it gives you |
|---|---|---|
| Free | Free | No sign up · no limit on query length · no daily limit |
The facts
Each one read from Public Tools SQL Formatter's own pages, with the date it was checked.
What it does
- Audience
- The page describes copying formatted queries back into an editor or migration, making it suitable for people working with SQL queries and migrations.checked 8 Oct 2001
- Dialect support
- Supports 20 dialects, including PostgreSQL, MySQL, SQL Server, Oracle PL/SQL, BigQuery, Snowflake, Redshift, Spark, Trino, DuckDB, ClickHouse, Db2, N1QL, SingleStore and TiDB.checked 8 Oct 2001
- Formatting options
- Users can choose uppercase, lowercase or as-typed casing, and two-space, four-space or tab indentation.checked 8 Oct 2001
- Limitations
- It does not validate query correctness, understand the user's schema, optimize queries or lint them; stored procedure bodies and vendor-specific scripting blocks are a known weak spot.checked 8 Oct 2001
- Multiple statements
- Semicolon-separated statements are formatted one after another with a blank line between them.checked 8 Oct 2001
- Offline use
- The page says users can disconnect after it loads and continue formatting queries.checked 8 Oct 2001
- Parsing errors
- The formatter parses the statement and reports the line and column when it encounters an unbalanced parenthesis or unclosed quote.checked 8 Oct 2001
- Private processing
- The formatter runs in the browser and the page says it makes no network requests after loading, so queries stay on the user's machine.checked 8 Oct 2001
- Purpose
- Formats SQL queries by changing whitespace and keyword casing.checked 8 Oct 2001
- Supported use
- The page says it is safe for production queries and requires no sign-up or email address.checked 8 Oct 2001
Alternatives to Public Tools SQL Formatter
- 1
Poor SQL
Free planOpen sourceWebAPIExtensionLinux7.3Free plan - 2
SQLFormat.org
Free planOpen sourceWebAPIExtensionSelf-hosted7.1Free plan - 3
sqlfmt
Free planWebAPILinuxSelf-hosted6.7Free plan - 4
RegSQL
Free planWeb6.5From $8 a month - 5
SQLCheck
Free planLinuxmacOSWindows6.5Free plan - 6
sqlfmt
Free planWebAPI6.5From $9 a month
