Format and beautify SQL. Pretty print or minify. Supports multiple dialects.
Format and beautify SQL queries. Raw SQL is often one long line—hard to read and debug. This SQL formatter adds indentation, line breaks, and consistent keyword casing (UPPER or lower). Also minify SQL to a single line for production. Supports PostgreSQL, MySQL, MariaDB, SQLite, and Transact-SQL.
Read complex queries, prepare SQL for documentation, debug long statements, share formatted code, or minify for deployment. Handles nested subqueries, CTEs, and most SQL syntax. All formatting in your browser.