Text Analyzer
Count words, characters, sentences, and more.
Statistics
About the Text Analyzer
The analyzer reports six counts for whatever you type or paste: words, characters, characters without spaces, sentences, lines and paragraphs. The numbers update on every keystroke and the text never leaves your browser. Each count has a precise definition, and knowing those definitions explains why this page, Microsoft Word, Google Docs and wc can disagree by a few units on the same text.
How each number is defined
- Words are runs of non-whitespace characters. A hyphenated compound such as
state-of-the-artis one word, a number such as3.14is one word, and an email address is one word. Text written without spaces between words, as in Chinese, Japanese or Thai, counts as a single word per line, so the word count is only meaningful for space-separated languages, including English and the Indian languages that separate words with spaces. - Characters is the length of the text as JavaScript measures it, which is UTF-16 code units. Spaces, punctuation and line breaks are included. See the next section for why an emoji counts as two.
- No Spaces removes every whitespace character first: spaces, tabs, line breaks and non-breaking spaces.
- Sentences are the non-empty pieces left after splitting on runs of
.,!and?. It is an approximation: decimals, abbreviations, URLs and ellipses all inflate the count. "Pi is 3.14. See e.g. this." reports five sentences rather than two. The Devanagari danda (।) used to end Hindi and Marathi sentences is not recognised, so sentence counts for those languages are not reliable. - Lines is the number of line breaks plus one, which matches what an editor shows in its gutter. A text that ends with a line break therefore reports one more line than
wc -l, which counts the break characters themselves. - Paragraphs are blocks separated by at least one blank line. A line containing only spaces counts as blank. A single line break inside a block does not start a new paragraph, which is the convention Markdown and most editors follow.
Characters, code units and graphemes
There are three honest answers to "how many characters is this?". Bytes depend on the encoding: in UTF-8 a Latin letter is one byte, a Devanagari letter three and most emoji four. Code points are the Unicode numbers behind the text. Grapheme clusters are what a reader perceives as one character. JavaScript's length, which this page reports, counts UTF-16 code units, which sit between code points and bytes.
| Text | Reported here (UTF-16 units) | Code points | Grapheme clusters |
|---|---|---|---|
| 😀 | 2 | 1 | 1 |
| 🇮🇳 (flag) | 4 | 2 | 1 |
| 👨👩👧 (family, joined with ZWJ) | 8 | 5 | 1 |
| नमस्ते | 6 | 6 | 3 |
| é typed as one code point | 1 | 1 | 1 |
| é typed as e plus combining accent | 2 | 2 | 1 |
The last two rows are the same visible letter in two encodings, which is why text should be normalised (NFC form) before comparing or deduplicating it. If you need grapheme counts in code, Intl.Segmenter with granularity: 'grapheme' is built into modern browsers and Node. Python's len() returns code points, which is why the same string gives a different number there.
Platform limits worth checking against
| Where | Limit | Note |
|---|---|---|
| SMS, GSM-7 alphabet | 160 characters | 153 per segment once the message is split into parts |
| SMS with any non-GSM character | 70 characters | One Hindi letter or emoji switches the whole message to UCS-2; 67 per segment when split |
| X (Twitter) post | 280 | Weighted count: CJK characters count double, every URL counts as 23 |
| Instagram caption | 2,200 | Hashtags included |
| LinkedIn post | 3,000 | Text is truncated with "see more" well before that |
| Google Play short description | 80 | Full description 4,000 |
| HTML title and meta description | about 60 and about 155 | Search engines truncate by pixel width, not a fixed count, so these are working guides |
Transactional SMS in Indian languages
An OTP or alert written in Hindi, Telugu or Tamil is sent as UCS-2, so the single-segment limit is 70 characters, not 160. Paste the template here and read the Characters count to check whether it fits in one segment before it is registered.Estimating reading and speaking time
This page does not compute a reading time, because the number depends on the reader. A widely used planning figure for adults reading English prose silently is 200 to 250 words per minute; technical material with code and numbers is read more slowly. For a talk or voice-over, 130 to 160 words per minute is a common planning pace. A 1,000-word article is therefore roughly four to five minutes of reading and about seven minutes of narration. Divide the Words count by the pace you trust for your audience.
Command-line equivalents
wc -w -l -m file.txt # words, newline characters, characters (per locale)
wc -c file.txt # bytes, not characters
grep -c '' file.txt # lines, counting an unterminated last line too
Get-Content file.txt | Measure-Object -Word -Character -Line # PowerShell
python3 -c "import sys; t=sys.stdin.read(); print(len(t.split()), len(t))" < file.txtPrivacy
Counting happens in the page as you type. Nothing is stored or transmitted, and the Copy Text button only copies your own input back to the clipboard.
How to use
- Type or paste text into the large box.
- The six counters above it update on every keystroke.
- Use Characters when a platform counts everything you type, and No Spaces when a form counts only visible characters.
- Copy Text puts the current text on the clipboard; Clear empties the box.
Common use cases
- Trimming an essay, cover letter or assignment to a strict word limit.
- Checking that a social post, SMS template or push notification fits the platform limit before you send it.
- Writing HTML titles and meta descriptions that will not be cut off in search results.
- Confirming how many lines a pasted list or log excerpt contains before importing it.
- Verifying that an OTP or alert template in an Indian language fits a single 70-character SMS segment.
- Estimating how long a script or article will take to read or narrate.
Frequently asked questions
Why is the word count different from Microsoft Word or Google Docs?
Why does one emoji count as two characters?
Does it count Hindi, Telugu or Tamil text correctly?
Why is the sentence count higher than the real number?
How does it decide where a paragraph ends?
Can it calculate reading time or a readability score?
Is there a limit on how much text I can paste?
Is my text stored anywhere?
Advertisement