Developer & Text · SQL & XML Formatter
Format or minify SQL and XML, and check XML is well-formed
Quick answer
Open Toolfox → SQL & XML Formatter, paste SQL or XML and choose Format or Minify; the result updates as you type. XML is checked for well-formedness, with the line and column of the first problem. It runs entirely on your computer (Mac, Windows or Linux). Files are never uploaded.
How to do it
- Open SQL & XML Formatter.
- Paste code or open a .sql or .xml file.
- Choose SQL or XML, Format or Minify, and an indent of 2 spaces, 4 spaces or tabs.
- Copy the result or Save… it.
Options you can set
- Language
- Indent
- Uppercase SQL keywords
- Keep XML comments when minifying
Good to know
- SQL is formatted, not validated: the formatter doesn't check that a query is correct. Minifying SQL removes comments.
- XML is checked for well-formedness, with the line and column of the first problem. It isn't validated against a schema or DTD.
- Elements that contain text keep their content exactly as written; whitespace between elements is treated as layout.
SQL & XML Formatter FAQ
Does it check my SQL for errors?
No. SQL is formatted, not validated. Minifying SQL also removes comments.
Does it validate XML against a schema?
No. It checks that XML is well-formed, not that it matches a schema or DTD.
Will it change the text inside XML elements?
No. Elements that contain text keep their content exactly as written; only whitespace between elements is treated as layout.
Is SQL & XML Formatter in Toolfox free?
Yes. SQL & XML Formatter is one of 57 tools in Toolfox, a free app for Mac, Windows and Linux with no account, ads, limits or watermarks.
Does SQL & XML Formatter upload my files?
No. Toolfox processes files on your own computer and works offline; your files are never uploaded.
More developer & text tools in Toolfox
Get SQL & XML Formatter and 19 more tools.
Free forever. No account. Works offline. For macOS, Windows and Linux.
Updated 2026-10-18 · Toolfox v0.2.1