I was trying to figure out the best accessibility techniques for screen-reader only text (color: transparent
, opacity: 0
, etc.) and came across a thread that got me thinking.
2 quotes from that post:
“[hidden text] risks search engine penalties – they can detect hidden,
transparent, or same-as-background text. In fact, it’s a
well-established technique for spamming and keyword stuffing, so the
engines tend to penalize it severely.”“What’s wrong with the old text-indent trick?” (
text-indent: -99999px
)
Questions:
-
Why doesn’t the text-indent technique get penalized?
-
If this technique allows for penalty free hidden text, why haven’t spammy sites ruined it for us yet? (via hidden keyword-stuffing)
-
My only thought, does this technique somehow not hold/get ignored for SEO value?
2
Answers
Keyword stuffing is no longer as effective as it once was. Search engines consider the overall content of the page, look at narrative structure, headings, the page
<title>
, the overall site, and so on.Blocks of content that do not fit the narrative tend to be ignored, independent of the CSS technique used to hide them.
Also, negative text indent is not truly hidden and causes problems when content or a site is translated to a right-to-left language, meaning that content can suddenly overlap or otherwise break.
Bear in mind that many sites today “hide” content in tabs, menus, accordions, etc. As such, hidden content is common and search engines cannot penalize just because it is hidden and maintain market share.
There is a bunch more detail offered in the late-2015 post How Does Google Actually Treat Content Hidden in Tabs or Click-to-Expand? It notes the following and links to two SO threads:
There are a bunch of SEO experts who have a lot of theories, and there are the guys who work for search engines who won’t deny anything.
If Google has algorithm to detect hidden keywords, this will penalize any hidden text they consider spammy.
Writing transparent text is obviously keyword stuffing. This is less evident for
text-indent: -9999px
text, but this might be one criteria among others.The conclusion I came is hiding text is not a solution : it might be helpful for screenreader users, but they are just a part of the people targeted by accessibility guidelines.
Use
aria-label
if you want to target screenreaders, not a CSS trick which might be projudiciable for universal accessibility and SEO.