The bookmarklet reads document.body.innerText, which MDN documents as returning the rendered text of the visible page (nav, article, footer combined). MDN: document.body.
Learn
How to Count Words on a Live Website
Three ways that work: paste, DevTools, or a bookmarklet.
Advertisement
1. Paste into the counter
The fastest way: select the article text, copy, then paste into the homepage counter. Works with any page you can read.
2. Browser DevTools
Open DevTools (F12 or right-click › Inspect). Switch to the Console. Paste: document.body.innerText.trim().split(/s+/).length. Enter. Chrome, Firefox, Edge, and Safari all support this.
3. Bookmarklet
Save this as a bookmark URL: javascript:alert(document.body.innerText.trim().split(/s+/).length + ' words'). Click the bookmark on any page to see the total.
What to expect
DevTools and the bookmarklet count everything visible on the page: article, nav, footer, related links. The paste method is cleaner because you select only the body text. Use it when you need an accurate article word count.
Advertisement
Advertisement
Common questions
Does the bookmarklet work on any site?
Yes on sites that render text in the DOM. Sites that render text inside a canvas element (some editors, some ebooks) are opaque to it.
What does document.body.innerText actually return?
The visible text on the rendered page. Skips hidden elements, aria-hidden nodes, and CSS display:none content.
Can I count words on a paywalled article?
Only the visible portion. If the paywall hides the article body, the counter reads the preview text.
Why does the article word count differ from the "reading time" label the site shows?
The site's reading-time label usually counts the article body only (excluding nav and footer); a paste-then-count of the selection matches it.
Is there a Chrome extension?
Not from Count My Page. The bookmarklet gives you the same result with no extension install.
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.