SEO & Content

HTML Word Counter

Paste a page’s HTML and get the word count of the visible text only. Tags, attributes, scripts and style blocks are ignored, so you measure content, not code.

  • 100% free
  • Private: runs in your browser
  • No sign-up
  • Live results
  • Updated

How to use the html word counter

  1. Copy the page source or the HTML of a section.
  2. Paste it into the box.
  3. Read the word, character, sentence and paragraph counts of the visible text.
  4. Use the extracted text to check keyword usage with the Keyword Density Checker.

Why count words in HTML

Pasting HTML into a normal counter inflates the total because tag names, attributes and inline scripts are counted as words. This tool parses the markup with the browser’s own HTML parser, removes script, style and template elements, and counts the text that a reader would see. It does not fetch pages by URL; copy the markup you want measured. Alt text and other attribute values are not visible text and are not counted.

For content audits, this gives a consistent measure across pages built with different templates, and helps spot thin pages.

Limits

The tool counts text in the markup you paste, not text injected later by JavaScript. Navigation, footers and cookie banners are counted if included, so paste just the main content area for a content-only figure. For a heading outline, use the Heading Counter; to copy the cleaned text, use the Plain Text Extractor.

Frequently asked questions

Does it count alt text?

No. Alt text is an attribute, not visible text.

Are comments counted?

No. HTML comments are ignored.

Can I enter a URL?

No. Paste the HTML source; nothing is fetched.

More tools for the same job