So apparently hiding content using "display: none" is bad for SEO and seen by googlebot as being deceptive. This according to a lot of the posts I read online and questions even on this site.

But what if I hide keyword rich text using javascript? A jquery example:

$(function() {

or using visibility hidden:

$(function() {
      visibility: 'hidden',
      position: 'absolute'

Would any of these techniques cause my site to be penalized? If googlebot can't read javascript then if I'm hiding through js it shouldn't know right?

What about using "text-indent: -9999px"?

2 Answers 2


It's not the technique, it the reason why you're doing it that matters. Based on your question you're clearly doing this to manipulate your search rankings. So whether you use JavaScript or CSS it's still cloaking and still against the terms of service of the search engines. Cloaking gets you banned if you get caught.

So, instead of trying to cheat the system, and everyone else looking for quality content, why not use the time you spend trying to cheat the system to create quality content that will naturally help your rankings?


It's only deceptive if there is no decent reason for it - Google examines html, javascript, and jQuery, to look for cloaking and if it detects anything like the above it will ban you.

Standard techniques like text-indent are not problematic. Just write some good content.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.