The importance of the issue
As far as I know, we don’t use the text to HTML ratio for anything. So this is something that some SEO tools came up with at some point. But from our point of view we don’t use that at all.
I wouldn’t focus on a metric like that unless there is something of value you can pull out of that for the users. Maybe what you could be looking at there is seeing that these pages are bloated HTML and when you serve them to users, especially on mobile, it slows everything down. Thats one aspect that could be playing a role there, which is more between you and your users.
John Mueller, Webmaster Trends Analyst at Google
But at least from a search or SEO point of view, we don’t look at the text to HTML ratio at all.
Despite this being an indirect Google ranking factor, it is not recommended to “pump” a HTML code relative to the useful content at a page, as it might have an indirect negative influence over your website. Redundant HTML code might slow down the page loading as well as its analysis by search robots.
How to check the issue
Use the data obtained from our text to code calculator or any other online service.
How to fix this issue
- Check the HTML code validity here https://validator.w3.org/.
- Delete the useless code.
- Delete large “empty” spaces from the code.
- Delete large comments from the code.
- Delete any hidden text that is not visible to users.
Detect pages with low text to code ratio
Crawl the website to collect all pages that have text to code ratio < 10%