😱 The truth about Google and JavaScript


Here’s the truth every SEO needs to know:

No matter how great your website is, if Google can’t index it due to JavaScript issues, you’re missing out on traffic opportunities.

JavaScript is a great option to make website pages more interactive and less boring.

But it’s also a good way to kill a website’s SEO if implemented incorrectly.

So here’s what you need to know about Google and JavaScript relationshipsšŸ‘‡šŸ‘‡šŸ‘‡

Google doesn’t interact with your content

Googlebot can’t click the buttons on your pages, expand/collapse the content, etc.

Googlebot can see only the content available in rendered HTML without any additional interaction.
​

Google doesn’t scroll

Googlebot does not behave like a usual user on a website, it doesn’t scroll through the pages. So if your content is ā€˜hidden’ behind an endless amount of scrolls, Google won’t see it.

Google doesn’t see the content that is rendered only in a browser vs on a server

That’s why client-side rendering is a bad idea if you want Google to index and rank your website (and you do want it if you need traffic and sales).

Ok, so is JavaScript really that bad?

The answer is ā€˜no’ if JavaScript is implemented on a website using best practices. And that’s exactly what I’m going to cover below.

āœ… Add links according to the web standards

Your relevant anchor text

NOT:

  • window.location.href=ā€˜/page-urlā€˜
  • #page-url (if you want it to be a separate page)

āœ… Add images according to the web standards

NOT:

āœ… Use server-side rendering

If you want Google to read and rank your content, you should make sure this content is available on the server, not just in a user’s browser.

You need to make sure that rendered HTML shows the right information such as:

  • Copy on the page
  • Images
  • Canonical tag
  • Title & meta description
  • Meta robots tag
  • Structured data
  • hreflang
  • Any other important tags

šŸš€ Psst... Did you know...

The Tech SEO Pro course has a dedicated JavaScript SEO module that will help you to learn how to make sure the JavaScript used on a website is SEO-friendly.

I'll show you a 3-step framework of JavaScript debugging (so you’ll know exactly how to do it in different settings and with any frameworks)

One of my key wins after Tech SEO Pro was identifying and solving a major JavaScript rendering issue on our product pages. Most of the key content wasn’t getting picked up by search engines. Thanks to what I learned in the program, I was able to diagnose it quickly and work with devs to implement a fix, which significantly improved indexation and visibility.

Manikandan N, Tech SEO Pro student

​Check out Tech SEO Pro now>>​

Grab this free resource šŸ‘‡

Truth about Google and JavaScript

Download a free PDF with a copy of this email, so it's easy for you to get back to it when you need (no signup required) šŸ‘‡šŸ‘‡šŸ‘‡

Smart SEO Newsletter

I'll help you trade an imposter syndrome for a technical SEO superpower. My mission is to break down and simplify complex technical SEO things so that you can understand and use them to advance your SEO career.

Read more from Smart SEO Newsletter

Someone has recently asked me about the most important technical SEO considerations for AI visibility. So I thought I'd share them with you. Here you go šŸ‘‡šŸ» 1. Allow AI Crawlers in your robots.txt Make sure your robots.txt does not block major AI bots: GPTBot (ChatGPT / OpenAI) ClaudeBot (Claude AI / Anthropic) PerplexityBot (Perplexity AI) Bingbot (used by Microsoft Copilot) Googlebot + Google-Extended (used by Google Gemini and AI Overviews) šŸ’” But if you want to block AI crawlers, robots.txt...

Heads up, I'm doing a series of super valuable tips to help you improve SEO <> Dev communication (and grow your paycheck). If you're not interested, click here to opt out but stay on the list. In the previous email, we agreed on this: The results of your work depend on your SEO recommendations being implemented by devs. That’s why SEO + Devs should šŸ¤ These 4 steps will help you collaborate with developers much more effectively by speaking the same language with them. Let’s go šŸ™Œ Step 1: Create...

As an SEO, you are always doing your best, even when it feels hard. That’s why it’s so painful when developers just ignore your SEO recommendations. It’s like they don’t even care. 😭 And it hurts even more when you realize that the results of your work depend on your SEO recommendations being implemented by devs. (So your performance is basically judged based on the things that are out of your control.) I’m sorry, my friend. It does feel hard to speak the same language with developers. But...