SEO & Marketing

JavaScript SEO: What Google Actually Sees from Your Site

If your pages are being indexed empty in Search Console, the problem is probably JavaScript rendering. Here you'll see what Google sees and how to fix it.

SEO & Marketing

Your page opens perfectly in your own browser, everything is in place, but in Search Console you see a "Page with redirect" or "Crawled – currently not indexed" report, and when you check the URL with site:, it's either not there at all or a version has been indexed that's just an empty skeleton. This is exactly where the discussion of JavaScript SEO turns from a theoretical topic into an operational problem. Google sees your page in two stages, and if the second stage fails, the content the user sees never makes it into the index.

Google's two-stage rendering: what actually gets indexed

Google's crawler first downloads the raw HTML. If the main links and text are in that HTML, the job is done. If they aren't, the URL goes into the render queue; a queue whose resources are limited and which sometimes takes hours or days. At that stage, Google runs the page in a headless browser, reads the JavaScript, and sees the final DOM.

The point many people miss is this: this queue is prioritized and its capacity isn't unlimited. Your site, with thousands of JavaScript-heavy URLs, is competing with the rest of the world for that same capacity. Every second rendering takes increases the chance the page gets indexed later or incompletely.

How to figure out what Google sees

You have three tools, and all three give different answers:

  • View Source in the browser: the same raw HTML the crawler sees first. If the main text isn't here, it means you're dependent on rendering.
  • URL Inspection in Search Console, the "Tested page" tab and the "View crawled page" section: the final rendered HTML. The difference between these two is exactly what you need to fix.
  • curl -s https://example.com/page | grep -c "keyword": the fastest manual test. If the output is zero and you see the text in the browser, the problem is confirmed.

In SEO and webmaster tools you can see index status and crawl errors side by side, but none of them replaces comparing View Source with View crawled page.

SSR or CSR: the choice that actually costs you

The simple answer is "use SSR." But this answer isn't right for everyone, and you need to know its cost.

ApproachInitial HTMLReal costWhen I'd choose it
Pure CSR (React/Vue SPA)Empty, just <div id="root"></div>Complete dependence on Google's render queueOnly for a user panel behind login that doesn't need SEO
SSR (Next.js, Nuxt)CompleteExtra Node server, caching, CPU costA content site with organic traffic
SSG (static generation)CompleteRebuilding when content changesBlogs and pages that change infrequently
Dynamic RenderingComplete for the crawlerTwo separate paths to maintainLegacy code that can't be rewritten

If you ask me: for a Persian content site, I'd choose SSG, and if the content were dynamic, SSR. I'd only accept pure CSR where the page is behind authentication. Dynamic Rendering isn't a solution, it's a painkiller; two versions of one page that always drift apart, and after six months nobody knows which one is correct.

The cost that's less often mentioned

SSR isn't free. A Node server with proper caching, under high traffic, can push TTFB from 200 milliseconds to over a second if you don't have layered caching. That means you've solved JavaScript SEO and created a speed problem. The right way: SSR with edge caching or page caching with stale-while-revalidate, not fresh rendering for every request. To learn how this number affects user experience, see the relationship between TTFB and load time.

Errors that show themselves in the logs

Here's where mistakes happen: the development team assumes that because everything is fine in Chrome, Google sees the same thing. Three recurring patterns:

  1. Click-dependent content. Tabs and accordions whose content is only built in the DOM after a click. Google doesn't click. The solution: content should be in the HTML and hidden with CSS, not built with JavaScript.
  2. Links built with onclick. The crawler doesn't follow the link because it isn't an <a href>. The sign in Search Console: pages that are linked on the site but stay "Discovered – currently not indexed."
  3. JavaScript errors only in Google's environment. A polyfill or browser API that isn't in headless Chrome halts the entire render and the page gets indexed empty. Test: fetch the same URL with curl -A "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" and see what comes back.

The common sign of all three in Search Console is the same: the page the user sees isn't in the index. And another sign is that in the "Coverage" report, the number of "Crawled – currently not indexed" pages keeps climbing without you having added duplicate content.

A common trap in robots.txt

If you block .js and .css files in robots.txt to reduce crawling, Google can't render the page. The result: a page that's complete in the browser becomes an empty shell in the index. This mistake has been repeated for years and is still seen on Persian sites. Leave static files open; if you're worried about server load, use a CDN, not blocking.

A practical checklist for a JavaScript-heavy site

Before any rewrite, measure these:

  • For 20 important URLs, compare the curl output with "View crawled page." Any difference in the main text is a bug.
  • In the browser's Network tab with throttling, see how many chained requests are needed before the content renders. If it's more than three hops, you have a structural problem.
  • Check DNS status and server response with technical domain and DNS lookup; sometimes the problem isn't rendering but a 5xx response or a redirect chain.
  • Measure real user speed with field data, not local Lighthouse. The method is covered in measuring real user speed with CrUX.

If your site is on WordPress and only part of the page is built with JavaScript, you usually don't need to change the whole architecture. Render that part server-side and keep the rest. A full rewrite is the last option, not the first.

When you don't want to get involved yourself

Some teams don't have the time or front-end expertise for this and would prefer to build the site from the ground up with the right architecture. In that case, ServerNet web design with server-side rendering from the start is a shorter path than patching an old SPA. And if you already have a site and just want to know where you stand on this spectrum, ServerNet's SEO services perform exactly this technical review.

One last point worth repeating: before any architectural decision, look at the page once through Google's eyes. Not through your own browser's eyes.

Frequently asked questions

Does Google execute JavaScript?

Yes, Google executes JavaScript in the second rendering stage. But this execution isn't immediate and happens in a queue with limited capacity that can take hours or days. That's why a page that only builds content with JavaScript gets indexed later and more incompletely.

So "it executes" isn't the same as "rely on it." The main content should be in the initial HTML.

How do I know whether Google sees my page's content or not?

In Search Console, Inspect the URL and compare the HTML tab with "View crawled page." If the main text wasn't in the raw HTML but was in the rendered version, your page is dependent on rendering.

A faster test: curl -s URL | grep "the phrase you're looking for". An empty output means the first crawler sees nothing.

Is Dynamic Rendering a good solution for JavaScript SEO?

Google accepts it as a temporary solution, not a permanent one. Its problem is that you maintain two versions of one page and they gradually drift apart. If you can do SSR or SSG, choose that.

I only recommend Dynamic Rendering when rewriting the site isn't possible in the short term and losing organic traffic is more expensive than maintaining two paths.

Does blocking JS files in robots.txt improve crawl speed?

No, and it usually has the opposite effect. Google needs those same files to render the page, and if it doesn't have access, it indexes the page incompletely or empty.

If you're worried about server load, serve static files from a CDN or set up HTTP caching; blocking just moves the problem from your server to Google's index.

ServerNet Support

ServerNet engineering & editorial team — specialists in infrastructure, networking and web hosting.

SEO Services
Share:

Comments 0

No comments yet — be the first!

Leave a comment

Related service

SEO Services

SEO is not a cost, it's an investment. With technical SEO, content strategy and principled link building, ServerNet raises your ranking on Google and builds real, lasting organic traffic.