← All toolsDeveloper›Data & Formats
SQL Formatter
Format one-line SQL queries into readable lines with uppercase keywords, one clause per line. Runs in your browser.
Tip from Tink: Paste the query from a log to see what it actually does.
SELECT u.id, u.email, count(o.id) as orders FROM users u LEFT JOIN orders o on o.user_id = u.id WHERE u.active = true AND o.created_at > '2026-01-01' GROUP BY u.id, u.email ORDER BY orders desc LIMIT 10
Advertisement
How to use the SQL Formatter
- Paste a SQL query.
- It's formatted as you type.
- Copy the result.
Everything runs in your browser. Nothing you enter is uploaded.