Code Formatters & Beautifiers
Minified or badly indented code is hard to read, review and debug. A formatter takes a wall of JSON, HTML or CSS and lays it out with consistent indentation and line breaks, so you can see the structure at a glance. The same tools also work in reverse: minify a file to strip whitespace and comments before it ships.
Every formatter here validates while it formats. For example, paste invalid JSON and you get the exact position of the error instead of a silent failure. Choose two spaces, four spaces or tabs to match your project's style guide, and use the line numbers to find the problem. The SCSS compiler goes one step further and turns Sass syntax (variables, nesting, mixins) into plain CSS the browser can use.
The minifiers go the other way. The JSON minifier strips whitespace and validates in the same pass. The CSS minifier removes comments and redundant characters without touching your selectors. The JavaScript minifier runs Terser, the same compressor most bundlers use. Each one shows the size before and after, so you can see whether the step was worth it.
All processing happens in your browser tab. That makes these tools safe for API responses that contain tokens, customer data or anything else you would not paste into a third-party server.
-
JSON Formatter
Beautify, validate and minify JSON.
-
HTML Formatter
Beautify or minify HTML with your choice of indentation.
-
CSS Formatter
Beautify or minify CSS with your choice of indentation.
-
SCSS to CSS Compiler
Compile SCSS to plain CSS.
-
JSON Minifier
Strip whitespace from JSON to shrink it.
-
CSS Minifier
Compress CSS by removing whitespace and comments.
-
JavaScript Minifier
Minify JavaScript with Terser in your browser.
-
SQL Formatter
Format and indent SQL queries.
-
XML Formatter
Beautify, minify and validate XML.
-
YAML Formatter & Validator
Validate, tidy and re-indent YAML.