Is Using .sr-only for Hidden SEO Keywords a Bad Idea?

0
0
Asked By CuriousCat87 On

I've been seeing some people use the `.sr-only` or `.visually-hidden` classes to secretly stash in extra keywords in their HTML. For example, someone might put "affordable laptops" hidden alongside a visible heading that says only "best laptops" to boost their SEO. Since screen readers can still pick up this hidden text, I'm wondering if this practice is seen as a smart strategy for SEO, a harmless little hack, or just plain risky that could get flagged by search engines. What do you all think?

5 Answers

Answered By SEOExpert101 On

Using `.sr-only` or `.visually-hidden` for hidden keywords is considered keyword stuffing. Google sees any hidden text intended to manipulate rankings as a big no-no, which could lead to penalties. Instead, focus on incorporating your keywords into the content that users can actually see.

DesignDiva -

But what if you just need a visually hidden title for a section? I've seen that done too.

Answered By CodeCrafty On

I tried using the `.sr-only` class just for accessibility—like adding ‘Close’ to a button, but my Lighthouse report flagged my links for not having descriptive text. Is that a bad move?

DevDude -

I’d suggest focusing on ARIA labels for context instead of hidden text. They give proper accessibility without risking SEO.

Answered By GoogleFaithful On

Google has been very clear about this: any hidden text or links meant to mislead users is treated as spam and goes against their spam policies. It’s best to use semantic HTML and ARIA attributes instead of trying to hide keywords.

Answered By AccessibilityAlly On

This is often called black hat SEO, and search engines are onto it! You could end up banned from search indexes if caught. Stick to visible content and leverage ARIA labels for accessibility instead of hidden text.

Answered By TechGuru99 On

Definitely not a good idea! Those classes should be used for accessibility, like making sure visually impaired users can understand what buttons do. If you slap hidden keywords in there just to game the system, you're risking penalties from Google.

WebWizKid -

Yeah, back in the day, people used to hide a ton of keywords that matched the background color! Totally frowned upon now.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.