Format
SQL Formatter
Paste SQL to format it with clean indentation and clause-per-line layout, choose keyword casing, and keep your comments intact. Everything runs locally.
SQL input
LocalFormatted SQL
FAQ
Common questions
It targets common ANSI-style SQL and works across MySQL, PostgreSQL, SQLite, and SQL Server for typical statements. It formats layout and casing rather than validating dialect-specific syntax.
Yes — keep as typed, force UPPERCASE, or force lowercase for recognized SQL keywords.
Yes. Both line comments (--) and block comments (/* … */) are kept in place.
No. Formatting happens entirely in your browser.
Private by design
This runs entirely in your browser
No file or text you enter here is uploaded. Encoding and decoding happen on your device using native browser APIs — close the tab and nothing remains on a server.