GlossarySEO
What is static site generation?
Also called: SSG, prerendering, static rendering, static export
Definition
Static site generation (SSG) builds each page's HTML once, at build time, and serves the same file to every visitor. It's the fastest and most reliable way to give crawlers complete pages.
Static site generation (SSG), explained
Instead of rendering a page for each request, a static site generator runs your components during the build, writes finished HTML files, and deploys them to a CDN. Every visitor and crawler gets a complete document straight from a nearby edge location. Next.js, Astro, Hugo, Eleventy and Gatsby all work this way, and Next.js App Router makes routes static by default when they don't read request-time data.
For SEO this removes most failure modes at once. Content, links, metadata and structured data are in the HTML. There's no render queue dependency, no per-request server work, and far fewer 5xx errors because there's no application code running when a crawler arrives. Time to First Byte is usually low because files come from a cache. Google's dynamic rendering page names static rendering as one of the recommended long-term approaches.
The trade-off is freshness. Content changes need a rebuild or a revalidation strategy. Incremental static regeneration and on-demand revalidation let you rebuild individual pages when data changes, which is how large programmatic sites stay static without rebuilding thousands of pages on every deploy.
A practical pattern: use typed data files or a CMS as the source, generate pages with generateStaticParams, set lastmod from the data's real change date, and only render dynamically where the page truly differs per request. This site is built that way.
Why it matters for founders
For marketing pages, docs, glossaries and programmatic pages, static generation gives crawlers the best possible version of every page at the lowest hosting cost.
Example
You generate 400 comparison pages from a typed data file at build time. Each is a static HTML file on the CDN, loads fast everywhere, and never fails because an API was slow when Googlebot arrived.
Common mistakes
- Opting pages into dynamic rendering by reading cookies or headers unnecessarily.
- Stamping every page's
lastmodwith the build date. - Rebuilding the whole site for every small content change on large sites.
- Generating pages from data that's too thin to stand alone.
Sources
- Google Search Central: Dynamic rendering as a workaround
- Google Search Central: Understand JavaScript SEO basics
Checked
Related terms
- Server-side rendering (SSR)Server-side rendering (SSR) means the server builds a page's full HTML for each request and sends it ready to display. Crawlers and users get content immediately, without waiting for JavaScript.
- Programmatic SEOProgrammatic SEO is creating many search-targeted pages from structured data and templates, such as one page per integration, city or comparison. It works when each page answers a real query with unique, useful data.
- lastmod
lastmodis the optional sitemap field that states when a URL's content last changed. Google uses it to schedule recrawls, but only if the dates are consistently accurate. - Time to First Byte (TTFB)Time to First Byte (TTFB) is the time from starting to navigate to a page until the first byte of the response arrives. It's not a Core Web Vital, but it delays everything after it, including LCP.