Monu Tools

SQL Formatter

Format and beautify SQL queries with clause line breaks and consistent keyword casing, or minify them to a single line.

How to use the SQL Formatter

  1. 01

    Paste your SQL query into the input box.

  2. 02

    Choose Format to beautify it or Minify to compress it to one line.

  3. 03

    Pick the keyword casing, then copy the result.

Frequently asked questions

What does the formatter do?

It puts each major clause such as SELECT, FROM, WHERE and JOIN on its own line, indents the columns and conditions, and normalises keyword casing for readability.

Is my SQL sent to a server?

No. Formatting runs entirely in your browser, so your queries never leave your device. That makes it safe for queries that mention table or column names.

Which SQL dialects are supported?

It is dialect-agnostic and handles common ANSI SQL used by PostgreSQL, MySQL, SQLite and SQL Server. It formats for readability rather than validating syntax.

About this tool

A SQL formatter that beautifies queries with clause line breaks, indentation and consistent keyword casing, or minifies them to a single line.

Everything runs in your browser, so it is fast and your queries stay private.

Related tools

We use essential cookies to run the site. With your consent we also load Google AdSense, which sets advertising cookies. See our privacy policy.