# Code and Markup Minify, Beautify, and Format Tools

Minify and beautify CSS, HTML, JavaScript, JSON, SQL, XML, YAML, TOML, SVG, and VBA, lint Markdown and email HTML, and format code across languages in one hub for production and review workflows.

> Canonical page: https://elysiatools.com/en/hubs/code-minify-beautify-format-tools

- **Category:** format

- **Keywords:** css minifier, javascript minifier, html minifier, json minifier, sql formatter, yaml formatter, xml formatter, toml formatter, svg minifier, beautify code, code formatter, markdown linter

## Overview

This hub groups the two opposite jobs that happen around every code and markup file: shrinking it for production and cleaning it up for review. The minifiers strip whitespace, comments, and redundant markup from CSS, HTML, JavaScript, JSON, and SVG so assets ship smaller. The beautifiers and formatters do the reverse, turning a minified or messy blob into readable, well-indented SQL, XML, YAML, TOML, or VBA. Two linters round out the set: a Markdown style checker and an email-HTML compatibility checker that flags what Gmail, Outlook, and Apple Mail will break. Use it to prepare a build, untangle a minified snippet, or make a config file reviewable before commit.

## Tools

- CSS Minifier: Compress CSS code
- CSS Beautifier: Format and beautify minified or messy CSS code into readable, well-indented stylesheets
- HTML Minifier: Compress HTML by removing comments, collapsing whitespace and minifying inline CSS/JS
- JavaScript Minifier: Compress JavaScript code
- JSON Minifier: Compress JSON data by removing all unnecessary whitespace
- SQL Query Formatter & Minifier: Beautify or minify SQL with full control over dialect (PostgreSQL, MySQL, SQLite, SQL Server/T-SQL, BigQuery, Snowflake, and more), keyword / identifier / function casing, indent style (standard, tabular-left, tabular-right), and spacing between statements. Produces a syntax-highlighted, copy-ready result with live size and statement stats.
- XML Formatter: Format, beautify and minify XML with configurable indent. Preserves comments and CDATA
- YAML Formatter: Format and beautify YAML. Note: comments are lost (js-yaml limitation)
- TOML Formatter: Format and beautify TOML. Note: comments are lost and key order may change (@iarna/toml limitation)
- Markdown Linter: Check Markdown for style issues: heading levels, code fences, list consistency, and more (zero-dependency rule engine)
- SVG Minifier & Analyzer: Analyze SVG markup, remove redundant elements, reduce payload size, compare before and after visually, and export cleaned files
- Code Formatter: Format code in various languages
- VBA Code Formatter: Format and beautify VBA code for better readability
- Email HTML Linter: Check email HTML templates for cross-client compatibility: unsupported CSS, non-inline styles, Outlook traps, table layout issues, and accessibility gaps.

## Samples

- MySQL Database Samples: Sample MySQL database scripts with various complexity levels from simple tables to enterprise ERP systems
- TOML Samples: TOML (Tom's Obvious, Minimal Language) format examples from simple to complex structures
- Kubernetes YAML Samples: Complete Kubernetes YAML manifests for Deployment, Service, ConfigMap, Secret, Ingress and other essential resources

## Frequently asked questions

### What is the difference between minifying and beautifying?

Minifying removes every byte that is not needed at runtime — whitespace, comments, semicolons, line breaks — so the file is as small as possible for the browser or parser. Beautifying does the opposite: it re-adds consistent indentation and line breaks so a minified or messy file becomes readable again. Most formats here have one of each.

### Which tools also lint, not just format?

Markdown Linter checks style issues like heading levels, code fences, and list consistency, and Email HTML Linter flags cross-client problems such as unsupported flex/grid CSS, non-inline styles, and Outlook rendering traps. The rest focus on minifying or formatting rather than rule-checking.

### Will formatting lose my comments?

It depends on the format. XML Formatter preserves comments and CDATA, but YAML Formatter and TOML Formatter warn that comments are lost because of how their underlying parsers work. The tool descriptions call this out so you know before running it on a config file whose comments matter.

### Can SQL Formatter handle my database dialect?

Yes. SQL Query Formatter and Minifier supports PostgreSQL, MySQL, SQLite, SQL Server/T-SQL, BigQuery, Snowflake, and more, with control over keyword and identifier casing, indent style, and statement spacing, and shows live size and statement stats.

## Related content

- [CSS Authoring, Layout, and Cascade Workflow Tools](https://elysiatools.com/en/hubs/css-authoring-layout-and-cascade-workflows): Format stylesheets, inspect selectors and specificity, build responsive type and layouts, preview motion, and generate CSS filters in one frontend styling hub.
- [SVG, Favicon, and Icon Asset Workflow Tools](https://elysiatools.com/en/hubs/svg-favicon-icon-workflows): Build favicon packs, optimize SVG assets, convert icons across ICO, PNG, JPG, WebP, and SVG, and prepare web-ready image assets in one hub.
- [JSON Inspection, Diff, and Transformation Tools](https://elysiatools.com/en/hubs/json-utility): Compare JSON formatting, diffing, path inspection, schema validation, merging, transformation, and export tools in one hub for API and data workflows.
- [Documentation Authoring, Extraction, and Publishing Tools](https://elysiatools.com/en/hubs/documentation-authoring-publishing): Write docs, extract docs from code or PDFs, review Markdown, and export polished documentation in one docs workflow hub.
- [Email Validation, MIME, and Domain Delivery Workflow Tools](https://elysiatools.com/en/hubs/email-mime-delivery-workflows): Validate email lists, inspect domains and DNS, prepare MIME-safe content, audit tracking URLs, and hand off HTML email content in one workflow hub.
- [SQL Query Review, Performance, and Relational Integrity Tools](https://elysiatools.com/en/hubs/sql-query-review-performance-and-integrity): Review SQL before it reaches production: format queries, assemble joins, inspect EXPLAIN plans, catch injection patterns, validate foreign keys, and compare schema drift in one focused hub.
