Format MySQL queries with the correct indentation, keyword casing, and line breaks for the MySQL dialect. Paste minified SQL and get a readable version back. All formatting runs in your browser.
Formatting runs entirely in your browser.
The tool uses the sql-formatter library, a dialect-aware SQL pretty-printer that runs entirely in your browser. It parses your query and re-emits it with consistent indentation and capitalisation. No server required.
All formatting happens locally in your browser tab. Our servers are not involved at any point.
For inspecting JSON returned by queries, try the JSON formatter. To validate identifier patterns in your SQL, use the regex tester. For converting query results into structured rows, see CSV to JSON.
Standard SELECT, INSERT, UPDATE, DELETE, and JOIN forms, plus MySQL-specific constructs like backtick-quoted identifiers, LIMIT/OFFSET, and ON DUPLICATE KEY UPDATE.
Formatting only adjusts whitespace and capitalisation. The execution plan, result set, and semantics of the query stay identical.
Yes. Separate statements with semicolons and paste them together. Each one is formatted independently.
All formatting runs in your browser using JavaScript. Our servers are not involved at any point.