Strip HTML tags
Transformed in your browser · nothing is uploaded
Removes HTML tags and leaves the text, turning block endings into line breaks so the result reads as paragraphs rather than as one run-on sentence.
How to use the strip html tags
The part naive tag-stripping gets wrong is script and style: removing only the tags leaves the JavaScript and CSS sitting in your output as text, which is both wrong and occasionally alarming. Their contents are removed entirely here. Block-level closings become line breaks so paragraphs survive, which a regex that simply deletes everything between angle brackets does not do. One thing worth knowing about security: stripping tags is not a sanitiser. If you are taking user HTML and putting it back into a page, you need an allowlist-based sanitiser, not a tag remover — the difference matters, and confusing them is a real vulnerability.
Questions
Yes. Removing only the tags would leave the JavaScript in the output, which is the bug in most tag-stripping regexes.
Yes, block-level closing tags become line breaks so the text reads as paragraphs.
No. Stripping tags produces plain text. Sanitising means allowing safe markup, which needs an allowlist library.
Choose the decode option to turn those back into their characters as well.
No.