跳到主要内容

Strip comments and whitespace between tags while keeping inline spacing and preformatted blocks exactly as they were.

正在加载工具…

Как пользоваться

3 шагов
  1. 01

    Paste your HTML source

  2. 02

    Tick “keep comments” to preserve them, or “keep newlines” if your template needs line structure

  3. 03

    Copy or download the compressed result

Частые вопросы

3 вопросов
Q1Will the contents of <pre> or <textarea> be damaged?

No. Those blocks are extracted first and put back verbatim after compression, so code blocks and preformatted text never deform.

Q2Why is there still a space between two <span> elements?

Because that space really renders. Whitespace between inline elements counts as one space in the browser; removing it would join the words into “ab”. Only whitespace between block-level tags is dropped.

Q3Are line breaks inside text removed?

They are folded into a single space, not deleted — otherwise <p>hello⏎world</p> would become helloworld.

Разработчику