Guide JavaScript Framework SEO

SEO pour JavaScript frameworks — React, Suivant.js, Vue, Nuxt, Angular, Svelte, and Astro. How rendering mode (SSR, SSG, CSR) determines ce que Google peut index, and qui frameworks handle SEO meilleur out of the box.

Première publication : 26 juin 2026 · Dernière mise à jour : 3 août 2026 · Advanced
Langues

JavaScript framework SEO comes bas to rendering mode: SSG and SSR give Googlebot pre-built HTML; CSR exige JavaScript execution que may or may pas succeed. Suivant.js and Nuxt have the la plupart built-in SEO prise en charge (SSR, SSG, ISR, metadata APIs). Pure React and Vue in CSR mode are the riskiest pour le SEO. Astro's island architecture is excellent pour le SEO by par défaut. Angular exige SSR via @angular/ssr (formerly Angular Universal) pour reliable indexation.

TL;DR — At the technical level, JS framework SEO is à propos de: (1) rendering architecture pour the initial HTML payload, (2) metadata injection into <head> avant la réponse is sent, (3) how the framework handles hydration and lien discovery, and (4) ISR cache staleness. Suivant.js has the la plupart complet built-in SEO tooling (Metadata API, built-in app/sitemap.ts, image optimization). Astro is the la plupart SEO-safe by architecture.

Rendering mode, metadata API, and ISR prise en charge by framework

Framework capabilities and defaults modifier by version; vérifier les in chaque framework’s Documentation officielle. Evidence for this claim Primary standard or official documentation supporting the adjacent article claim. Scope: Protocol semantics and Search behavior are kept separate; no indexing, ranking, or migration-timing guarantee is inferred. Confidence: high · Verified: web.dev: Rendering on the Web Aucun rendering mode guarantees indexation or rankings. Evidence for this claim Primary standard or official documentation supporting the adjacent article claim. Scope: Protocol semantics and Search behavior are kept separate; no indexing, ranking, or migration-timing guarantee is inferred. Confidence: high · Verified: Google: JavaScript SEO basics Quand you’re comparing frameworks pour a decision, tester the même routes, content, deployment target and tooling pour chaque candidate — a benchmark que swaps quelconque of ceux isn’t measuring the framework, it’s measuring the difference in setup.

FrameworkPar défaut renderingBuilt-in metadata APISSR/SSG prise en chargeEcosystem SEO prise en charge
AstroSSG (islands)Yes (<head> in .astro fichiers, Content Collections pour données structurées)Les deuxStrong
Suivant.jsSSR/SSG (configurable)Yes (Metadata API in App Router)Les deux + ISRExcellent
NuxtSSR by par défautYes (useHead, useSeoMeta)Les deux + ISRExcellent
SvelteKitSSR by par défautYes (svelte:head)Les deuxBon
React Router (framework mode)SSR by par défautYes (meta export)SSR + DeferredBon
AngularCSR by par défautVia Angular Meta/Title servicesVia @angular/ssrModerate
React (bare)CSRManual (react-helmet-async; react-helmet is unmaintained)Via Suivant.js/GatsbyDépend on wrapper
Vue (bare)CSRManual (@unhead/vue; vue-meta is unmaintained)Via NuxtDépend on wrapper

Remix v2 and React Router v7 merged — Remix’s server rendering and data-loading model now ships as React Router’s “framework mode,” and that’s the stable upgrade chemin pour Remix v2 apps. Remix 3 is a separate, experimental React-less rewrite (beta), pas the successor to Remix v2 — don’t treat it as a drop-in SSR option pour a React codebase.

Metadata timing, crawlable liens, and ISR cache staleness

Metadata injection timing — Metadata (<title>, <meta>) doit be in the server réponse, pas ajouté by JavaScript après page charger. Suivant.js’s Metadata API, Nuxt’s useSeoMeta, and Astro’s <head> component handle ce correctement. document.title = '...' or React Helmet in CSR mode ne fait pas — it runs après the initial HTML is served.

Lien discovery — Googlebot discovers liens by parsing HTML. Liens ajouté via JavaScript (onClick, dynamic routing sans <a> tags) may pas be découvert. Utiliser réel <a href> elements pour important navigation.

Hydration and contenu dupliqué — Si SSR and CSR render différent content (hydration mismatch), vous may fin up with indexé content que doesn’t match ce que utilisateurs voir. Tester pour hydration errors in le navigateur console.

Soft 404s — Client-side routers peut silently render a “page not found” UI pendant que returning a 200 HTTP status. Moteur de recherches index ces as réel pages. Assurez-vous votre 404 page renvoie a réel 404 status, and server-side redirections retourner 301.

ISR cache invalidation — In Suivant.js and Nuxt ISR setups, stale pages peut be served to robots d’exploration during the revalidation window. Définir a time-based revalidate interval, and pour content que changements on a schedule vous don’t contrôler (a CMS enregistrer, Par exemple), pair it with on-demand revalidation triggered from a webhook-backed route handler — voir the Suivant.js ISR guide pour the complet API.

// app/blog/[id]/page.tsx — time-based revalidation
export const revalidate = 3600 // re-check this page at most once an hour

// app/api/revalidate/route.ts — on-demand revalidation, called by a CMS webhook
import { revalidatePath } from 'next/cache'
import { NextRequest, NextResponse } from 'next/server'

export async function POST(request: NextRequest) {
  const { path, secret } = await request.json()
  if (secret !== process.env.REVALIDATE_SECRET) {
    return NextResponse.json({ message: 'Invalid secret' }, { status: 401 })
  }
  revalidatePath(path) // e.g. '/blog/1' — next request regenerates fresh HTML
  return NextResponse.json({ revalidated: true })
}

Add an expert note

Pin an expert quote

New person? Create their unclaimed profile at /admin/experts/ → Pin a quote first.