---
name: "html-beautify"
section: "1"
platform: "linux"
package: "node-js-beautify"
version: "1.13.6+dfsg+~0.15.3-1"
release: "Debian 11 (Bullseye)"
platforms: ["linux"]
url: "https://new.carta.tech/html-beautify"
---

# html-beautify(1)

html-beautify

## NAME

html-beautify.js - html-beautify

## DESCRIPTION

html-beautify.js@1.13.6

### CLI Options:

- **-f**, **--file**

  Input file(s) (Pass '-' for stdin)

- **-r**, **--replace**

  Write output in-place, replacing input

- **-o**, **--outfile**

  Write output to file (default stdout)

- **--config**

  Path to config file

- **--type**

  \[js\|css\|html\] \["js"\]

- **-q**, **--quiet**

  Suppress logging to stdout

- **-h**, **--help**

  Show this help

- **-v**, **--version**

  Show the version

### Beautifier Options:

- **-s**, **--indent-size**

  Indentation size \[4\]

- **-c**, **--indent-char**

  Indentation character \[" "\]

- **-t**, **--indent-with-tabs**

  Indent with tabs, overrides **-s** and **-c**

- **-e**, **--eol**

  Character(s) to use as line terminators. \[first newline in file, otherwise "\\n\]

- **-n**, **--end-with-newline**

  End output with newline

- **--indent-empty-lines**

  Keep indentation on empty lines

- **--templating**

  List of templating languages (auto,none,django,erb,handlebars,php,smarty) \["auto"\] auto = none in JavaScript, all in html

- **--editorconfig**

  Use EditorConfig to set up the options

- **-b**, **--brace-style**

  \[collapse\|expand\|end-expand\] \["collapse"\]

- **-I**, **--indent-inner-html**

  Indent body and head sections. Default is false.

- **-H**, **--indent-handlebars**

  Indent handlebars. Default is false.

- **-S**, **--indent-scripts**

  \[keep\|separate\|normal\] \["normal"\]

- **-w**, **--wrap-line-length**

  Wrap lines that exceed N characters \[0\]

- **-A**, **--wrap-attributes**

  Wrap html tag attributes to new lines \[auto\|force\|force-aligned\|force-expand-multiline\|aligned-multiple\|preserve\|preserve-aligned\] \["auto"\]

**-i**, **--wrap-attributes-indent-size** Indent wrapped tags to after N characters \[indent-level\]

- **-p**, **--preserve-newlines**

  Preserve line-breaks (**--no-preserve-newlines** disables)

- **-m**, **--max-preserve-newlines**

  Number of line-breaks to be preserved in one chunk \[10\]

- **-U**, **--unformatted**

  List of tags (defaults to inline) that should not be reformatted

- **-T**, **--content\_unformatted**

  List of tags (defaults to pre) whose content should not be reformatted

- **-E**, **--extra\_liners**

  List of tags (defaults to \[head,body,/html\] that should have an extra newline

- **--unformatted\_content\_delimiter**

  Keep text content together between this string \[""\]
