SQL Formatter
Pretty-print + minify SQL
296 chars
SQL input
Formatted
SELECT u.id, u.email, COUNT(o.id ) AS order_count, SUM(o.total_cents )/100.0 AS revenue FROM users u LEFT JOIN orders o ON o.user_id = u.id AND o.status = 'paid' WHERE u.created_at > '2024-01-01' AND u.deleted_at IS NULL GROUP BY u.id, u.email HAVING COUNT(o.id ) > 5 ORDER BY revenue DESC LIMIT 50;
Minified · 296 chars
select u.id, u.email, count(o.id) as order_count, sum(o.total_cents)/100.0 as revenue from users u left join orders o on o.user_id = u.id and o.status = 'paid' where u.created_at > '2024-01-01' and u.deleted_at is null group by u.id, u.email having count(o.id) > 5 order by revenue desc limit 50;
Related tools
More browser-only tools, free and no upload.
Regex Tester
Live regex with groups + flags
CSV to JSON
CSV → JSON, RFC 4180
JSON to CSV
JSON → CSV, header-aware
Case Converter
12 cases, all at once
Unix Timestamp Converter
Unix ↔ ISO, every format
URL Encoder & Decoder
URL, form, base64, HTML, 5 modes
Markdown Table Generator
Visual table → Markdown
Lorem Ipsum Generator
Deterministic seeded filler text
Questions
- Is SQL Formatter free?
- Yes. SQL Formatter is completely free, with no account, no sign-up, and no usage limits. It runs entirely in your browser.
- Do my files get uploaded when I use SQL Formatter?
- No. SQL Formatter processes everything on your device, so your files and text never leave your browser. You can verify it yourself: open your browser's Network tab and you'll see no uploads.
- How do I use SQL Formatter?
- Open SQL Formatter in your browser, no install or sign-up needed, then paste, type, or drop in your input and the result appears instantly. Pretty-print SQL queries with consistent indentation, keyword casing, and one-column-per-line SELECT layout. Plus a minified one-liner. Handles subqueries, JOINs, CTEs. Browser-only.
- Is there a file size limit in SQL Formatter?
- There's no hard file or text size limit. Because SQL Formatter runs locally in your browser, the only ceiling is your device's available memory, and everyday files process instantly.