Text To HTML Ratio Analysis
The Text to HTML Ratio Test measures the proportion of visible text content versus total HTML byte size on any URL. A healthy ratio (15-30%) indicates content-rich pages where users (and Googlebot) get plenty of substance per byte. Very low ratios (<10%) usually signal template overhead, inline JSON bloat, or thin content — all of which can suppress rankings on competitive keywords.
What This Tool Checks
- Total HTML bytes
- Visible text bytes (extracted from DOM)
- Text-to-HTML percentage
- Inline CSS and JavaScript overhead
- Inline JSON data overhead
- Comments and whitespace bloat
Why It Matters for SEO
Google ranks pages on substantive content. Pages with very low text-to-HTML ratios — say, 5% — usually have template wrappers, inline JSON for app hydration, or thin content. None of these signals correlate with strong rankings on competitive terms. The ratio is not a direct ranking factor, but a low ratio is a strong indicator of bloated templates or thin content that need fixing for other reasons.
How to Fix It
Audit the HTML payload — strip inline data not needed above the fold, externalise inline CSS / JS, remove dev comments. If the ratio is low because content is thin, expand the content with substantive copy that serves user intent. The goal is more substance, not less template.
How It Works
We render the page, extract visible text (excluding script, style, hidden elements), and compare its byte size to the raw HTML response size. The ratio plus overhead breakdown reveals whether the page is content-heavy or template-heavy.
Common Mistakes to Avoid
- Treating ratio as a magic number to game (it is a symptom, not a cause)
- Inlining huge JSON payloads on every page render
- Empty CMS templates dressed up with massive footers and navigation
- Server-rendering tab content that is hidden by default
- Forgetting that the fix is more / better content, not less HTML
Quick Checklist
- Text-to-HTML ratio between 15% and 30%
- Substantive content above the fold
- No huge inline JSON payloads
- Inline CSS / JS minimised
- Page word count appropriate to keyword competition