Last updated
Why Character Counts Matter
Different platforms enforce strict character limits, and exceeding them silently truncates your content or throws an error. Knowing your exact character count before publishing saves time and prevents embarrassing cut-off text. Here are the limits you'll encounter most often:
| Platform / Field | Limit | Notes |
|---|---|---|
| X (Twitter) post | 280 chars | URLs count as 23 chars regardless of length |
| Google meta title | ~60 chars | Pixel-based; ~60 chars is a safe estimate |
| Google meta description | ~160 chars | Longer descriptions get truncated in SERPs |
| SMS message | 160 chars | GSM-7 encoding; Unicode reduces this to 70 |
| LinkedIn post | 3,000 chars | First 210 chars show before "see more" |
| Instagram caption | 2,200 chars | First 125 chars visible without expanding |
| YouTube title | 100 chars | ~70 chars shown in search results |
| MySQL VARCHAR | 65,535 bytes | UTF-8 chars can be 1–4 bytes each |
Characters vs Bytes: The Difference Matters
A character counter counts Unicode code points, but databases and APIs often enforce byte limits. ASCII characters (A–Z, 0–9, common punctuation) are 1 byte each in UTF-8. Most European characters with accents (é, ü, ñ) are 2 bytes. Chinese, Japanese, and Korean characters are typically 3 bytes. Emoji are 4 bytes — a single 😀 counts as 1 character but 4 bytes.
This matters when you're storing text in a database column defined as VARCHAR(255):
255 bytes, not 255 characters. A string of 255 emoji would require 1,020 bytes and overflow the column.
Word Count for Reading Time Estimation
The average adult reads approximately 200–250 words per minute for non-fiction content. Blog posts and articles typically aim for:
- 300–600 words: Short-form content, news articles, social posts.
- 1,000–1,500 words: Standard blog posts, good for SEO.
- 2,000–3,000 words: In-depth guides, pillar content — tends to rank better for competitive keywords.
- 5,000+ words: Comprehensive resources, whitepapers, technical documentation.
Google's quality guidelines don't specify a minimum word count, but thin content (under 300 words) on pages that should be informative is a common cause of poor rankings.
JavaScript: Count Characters in Real Time
const textarea = document.getElementById('myTextarea');
const counter = document.getElementById('charCount');
const LIMIT = 280; // Twitter limit
textarea.addEventListener('input', () => {
const len = textarea.value.length;
counter.textContent = `${len} / ${LIMIT}`;
counter.style.color = len > LIMIT ? 'red' : 'inherit';
});
// Count words
function wordCount(str) {
return str.trim() ? str.trim().split(/\s+/).length : 0;
}
// Estimate reading time (200 wpm)
function readingTime(str) {
const words = wordCount(str);
const minutes = Math.ceil(words / 200);
return minutes === 1 ? '1 min read' : `${minutes} min read`;
}