Key takeaways
- Google processes JavaScript sites in three phases: crawl → render → index. Rendering can be delayed and isn’t guaranteed to catch everything.
- Server-side rendering (SSR) or static generation is the safest choice for pages that need to rank.
- Use real links, unique URLs, server-rendered meta tags and correct status codes — and test with URL Inspection.
When businesses move to React, Vue or Angular apps, organic traffic sometimes drops sharply. The content looks the same to users, but search engines receive an almost empty HTML shell and a large JavaScript bundle. This guide explains how Google handles JavaScript and how to build apps that rank — something I deal with regularly when building SaaS products and marketing sites side by side.
How Google processes JavaScript#
- Crawl: Googlebot fetches the URL and reads the raw HTML response. Links in that HTML are discovered immediately.
- Render queue: pages that need JavaScript wait for Google’s Web Rendering Service (an evergreen Chromium) to execute them. This is usually quick but can take longer.
- Render: scripts run, API calls are made, the DOM is built.
- Index: Google indexes the rendered HTML and discovers any new links.
Things that can go wrong: scripts blocked by robots.txt, API calls that time out, content that appears only after scrolling or clicking, and errors in older-syntax fallbacks. Other search engines and many AI crawlers do little or no rendering.
Rendering strategies compared#
| Strategy | How it works | SEO | Typical tools |
|---|---|---|---|
| Client-side rendering (CSR) | Browser builds the page from JS | Risky for important pages | Create React App, plain Vite SPA |
| Server-side rendering (SSR) | Server sends complete HTML for each request; JS hydrates it | Excellent | Next.js, Nuxt, SvelteKit, Remix |
| Static site generation (SSG) | HTML generated at build time | Excellent | Next.js, Astro, Hugo, Eleventy |
| Incremental / hybrid | Static pages regenerated on a schedule or on demand | Excellent | Next.js ISR, Nuxt hybrid |
| Dynamic rendering | Serve pre-rendered HTML to bots only | Workaround; no longer recommended by Google | Prerender services |
Need a hand with this?
Get a quick, honest review of your website’s SEO.
The JavaScript SEO checklist#
- Links: use
<a href="/pricing/">. Router link components usually render this correctly; avoidonClicknavigation on divs and buttons. - URLs: each view that should rank gets its own path-based URL (History API), not
#/pricing. - Metadata: title, description, canonical, robots and Open Graph tags must be in the server HTML for each URL.
- Structured data: render JSON-LD on the server where possible.
- Status codes: a “not found” view must return a real 404 (or add
noindex) — otherwise you create soft 404s. - Content on load: don’t require clicks, scrolls or logins to load main content; lazy-load below-the-fold content with IntersectionObserver, not scroll events.
- Resources: don’t block
.js,.cssor API endpoints needed for rendering in robots.txt. - Performance: code-split bundles and keep hydration light; huge bundles hurt INP and LCP.
- Images: real
<img>elements withsrc/srcsetand alt text.
How to test#
- View source vs Inspect: if the main content only appears in Inspect, it depends on rendering.
- Search Console URL Inspection → Test live URL → View tested page: check the rendered HTML, screenshot and any resource errors.
- Rich Results Test also shows rendered HTML for quick checks without Search Console access.
- Search Google for a unique sentence from a JS-loaded section in quotes to confirm it’s indexed.
- Crawl with JavaScript rendering enabled (Screaming Frog, Sitebulb) and compare with a non-rendered crawl.
Common problems I see#
- Every page has the same title and canonical because they’re set once in the app shell.
- Infinite scroll product lists with no paginated URLs.
- Content fetched from an API that rate-limits or blocks Googlebot.
- Cookie consent walls that hide content until accepted.
- Migrating from WordPress to a SPA without redirects or server rendering.
JavaScript SEO FAQ#
Can Google index React websites?#
Yes, Google can render React. But server-side rendering or static generation is more reliable, faster and works for other search engines and AI crawlers too.
Is Next.js good for SEO?#
Yes. Next.js supports SSR and static generation, metadata APIs and sitemaps, making it a strong choice for SEO-focused React sites.
Does WordPress have JavaScript SEO problems?#
Generally no, because WordPress sends complete HTML. Problems arise only when themes or plugins load main content via JavaScript.