How to use HTML Minifier
Remove HTML comments and inter-tag whitespace conservatively. Conservative minification removes comments and whitespace between tags. Inputs containing script, style, pre or textarea are rejected to prevent altering sensitive content.
- Set Input.
- Run the tool, review the result and its stated limitations, then copy or download if needed.
Example & practical use
Remove HTML comments and inter-tag whitespace conservatively. The example below demonstrates Input.
Example input:
{
"text": "<div> A </div> \n <p>B</p>"
}
Expected result (relevant fields):
"<div> A </div><p>B</p>"Features & result limitations
Conservative minification removes comments and whitespace between tags. Inputs containing script, style, pre or textarea are rejected to prevent altering sensitive content.
Frequently asked questions
What inputs does HTML Minifier accept?
Input
How should I interpret the HTML Minifier result?
Conservative minification removes comments and whitespace between tags. Inputs containing script, style, pre or textarea are rejected to prevent altering sensitive content.
Where does HTML Minifier process my data?
Inputs are processed locally in your browser. Submitted text is not sent to external services. A successful-run event increments an aggregate tool counter without your input.