That page doesn't exist. Search or drop a file below to find the tool you need.
What do you need to get done?
- Stays on this device
- No watermark
- Works offline
Drop a file here
or .
Open an app
Follow a recipe
Use one tool
SQL formatter
Format SQL online: paste a long query on one line and get it back with clear line breaks and indentation. Pick one of 16 dialects, including PostgreSQL, MySQL, SQLite and SQL Server (T-SQL). Free, and your queries stay in your browser.
How to format an SQL query
- 1Paste your SQL or drop a text file
- 2Choose the dialect, for example PostgreSQL
- 3Pick the indent and keyword case, then copy the result
- A readable query with one clause per line.
What you get
- Nothing is uploaded.Your queries, table names and column names are formatted in your browser.
- 16 dialects.From Standard SQL to PostgreSQL, MySQL, MariaDB, SQLite, T-SQL, Oracle PL/SQL, BigQuery and Snowflake.
- You set the style.Indent with 2 spaces, 4 spaces or a tab, and choose how keywords are written.
What you can do
- Pick a dialect: Standard SQL, PostgreSQL, MySQL, MariaDB, SQLite, SQL Server (T-SQL), Oracle PL/SQL, BigQuery, Snowflake, Redshift, Spark, DuckDB, ClickHouse, Db2, Hive or Trino.
- Write keywords in UPPERCASE, lowercase or as written.
- Indent with 2 spaces, 4 spaces or a tab.
- Switch the action to "Minify" to go the other way.
Good to know
- A query the formatter cannot read shows an error. Check the syntax or pick another dialect.
- The formatter changes layout, not meaning. It does not run or check your query against a database.
- The result is saved as a .txt file, named formatted.sql.txt.
Questions
Which SQL dialects are supported?
16: Standard SQL, PostgreSQL, MySQL, MariaDB, SQLite, SQL Server (T-SQL), Oracle PL/SQL, BigQuery, Snowflake, Redshift, Spark, DuckDB, ClickHouse, Db2, Hive and Trino.
Is my SQL sent anywhere?
No. The formatting runs in your browser. Nothing is uploaded.
Why do I get a syntax error?
Often the dialect does not match the query. Try another one, or check for a missing quote or bracket.
Can I keep my keywords in lowercase?
Yes. Under "Keywords" choose "lowercase" or "As written".