HTML-Minifier

github.com/j9t/html-minifier-next Web Development Open-source projectOpen source

Minify web page markup with HTML-Minifier, a configurable and tested successor to HTML Minifier.

github.com/j9t/html-minifier-next
HTML-Minifier homepage screenshot

About HTML-Minifier

HTML Minifier Next is a JavaScript tool that minifies HTML pages, including embedded CSS, JavaScript, and SVG. It can be run from the command line for files, directories, and piped input, or installed as a development dependency for programmatic use.

It is ESM-only and requires Node.js 22.13 or later. It is largely compatible with HTML Minifier and HTML Minifier Terser, but is not fully drop-in, so existing configurations may need migration changes.

Key features

  • Minifies HTML plus embedded CSS, JavaScript, and SVG
  • Command-line interface for single files, directories, and STDIN/STDOUT
  • Zero-config mode minifies HTML files in place in current folder
  • Conservative and comprehensive preset configurations
  • JSON configuration file with command-line overrides
  • Multi-threaded processing with configurable worker count
Best for: Developers who need to reduce HTML page size using Node.js command-line or programmatic tooling.
Good for
  • Handles HTML, embedded CSS, JavaScript, and SVG in one tool
  • Offers both command-line and programmatic use
  • Provides presets, config file, dry-run and verbose reporting options
Watch out for
  • Requires Node.js 22.13 or later and is ESM-only
  • Not fully drop-in compatible with HTML Minifier and HTML Minifier Terser
  • Automatic config file detection only checks the current working directory

HTML-Minifier at a glance

Type
Open-source project
Pricing
Not confirmed. Check the site
Open source
Yes · Source code
Language
English
Last checked
Oct 5, 2026 · Online when checked
Listed
Oct 5, 2026

HTML-Minifier alternatives

Tools and sites you could use instead, ranked by how closely they match.

All 15 alternatives

SVG2JSX

svg2jsx.com

Convert SVG markup into valid JSX with this browser-based editor, which accepts pasted code or uploaded files.

Transform

transform.tools

Convert data between formats such as SVG, JSX, JSON, schemas, and programming language structures with Transform.

SVG.wtf

svg.wtf

The page exposes SVG editing controls for adding and adjusting shapes, text, paths, and other elements.

Popular in Web Development

Well-known listings from the same topic.

All 122

HTML-Minifier FAQ

What are the requirements to install it?
It is ESM-only and requires Node.js 22.13 or later. Use npx for command-line use or install with npm i -D html-minifier-next for programmatic use.
How do I use it without configuration?
Run npx html-minifier-next --zero to minify HTML files in the current folder and its subfolders in place.
Is it compatible with HTML Minifier?
It is largely compatible with HTML Minifier and HTML Minifier Terser but is not fully drop-in; migration guidance is in the changelog.
Is something wrong or out of date?

Tell us and an editor will check it.

Own this website?

Claim the listing and suggest updates yourself. An editor checks every claim first.

Claim this listing