SQL Formatter
What is SQL Formatter?
SQL Formatter is a tool that takes raw or poorly formatted SQL queries and rewrites them with consistent indentation, keyword casing, and line breaks — making them far easier to read, review, and debug. Whether you're dealing with a minified query from an ORM or a legacy stored procedure, this tool cleans it up instantly in your browser with no data sent to any server.
How to Use the SQL Formatter
-
Paste your SQL query into the input box (or click 'Example' to load a sample).
-
Select your SQL dialect (MySQL, PostgreSQL, SQLite, etc.) to apply dialect-specific formatting rules.
-
Choose the indentation style and keyword casing that matches your team's conventions.
-
Click 'Format' to instantly format the query.
-
Copy the formatted SQL using the 'Copy' button.
Keywords: SQL formatter, SQL beautifier, format SQL online, SQL pretty print, MySQL formatter, PostgreSQL formatter, SQL query formatter, SQL indenter