Glossary · Development

What is a static site generator?

A static site generator is a tool that builds a website’s pages into ready-made HTML files ahead of time, from templates and content, so a server or CDN can deliver them instantly without assembling each page on request.

Why it matters

Pros and limits of a static site

Pre-built pages are fast, cheap to host and hard to break. There is no database to attack and no server code to patch on every request, and each page arrives as complete HTML that search engines and AI crawlers can read immediately. That makes static sites the usual choice for content and marketing sites, docs and blogs, served from a CDN.

The limits: content changes need a rebuild, very large sites take longer to build, and personalized or highly dynamic pages need extra work. Modern frameworks such as Astro and Next.js blur the line by mixing static pages with server-rendered ones where needed.

Our approach

How we use a static site generator

We use static generation for most marketing sites we code, usually with Astro, and connect a headless CMS so edits trigger a rebuild. Our own website is built by a small generator written for it, with no framework dependencies, because it is the clearest way to keep every page, price and link generated from one source.

See Astro development and how the site itself fits into our process.

Related service: Astro development · How we work

Example

Static site generator in practice

This website is a static generated site. Page content lives as data in content modules; a build script renders every page to an HTML file, writes the sitemap, robots.txt and llms.txt, and records what it generated. A separate check script then opens every file, resolves every internal link, validates the structured data and fails the build on errors. The output is plain files that any host can serve.

Avoid

Common mistakes

  • Forcing dynamic features into static pages. Logged-in dashboards and real-time data belong in an app or server-rendered routes.
  • Slow builds at scale. Thousands of pages can take minutes to rebuild. Use incremental builds or on-demand rendering for large content.
  • No editing workflow. Without a CMS, every change needs a developer. Plan for editors from the start.
How it works

How a static site generator works

  1. 01

    Write content

    Pages start as Markdown files, data files or entries in a headless CMS.

  2. 02

    Add templates

    Layouts and components define how each type of page looks.

  3. 03

    Run the build

    The generator combines content and templates and renders every page to HTML.

  4. 04

    Deploy to a CDN

    The HTML, CSS and images go to a CDN that serves them from a location near each visitor.

  5. 05

    Rebuild on change

    An edit in the CMS or a code commit triggers a new build, so the site stays current.

Tools

Popular static site generators

The right SSG depends on your team’s language and how much content you have. Checked December 2026.

GeneratorLanguageBest fit
AstroJavaScript, TypeScriptContent and marketing sites with interactive parts where needed
HugoGoLarge content sites and docs that rebuild often
EleventyJavaScriptSimple sites and blogs with flexible templates
JekyllRubyBlogs and project sites on GitHub Pages
Next.js static exportJavaScript, ReactReact teams that want static pages now and server features later
Rendering

Static, server-rendered or hybrid

Static generation is one of three ways to render a site; pick by how often the content changes and how personal each page is.

ModelHow pages are madeFits
StaticBuilt to HTML ahead of timeMarketing sites, docs, blogs
Server-renderedBuilt on the server for each requestLogged-in pages, live data, personalization
HybridStatic by default, server-rendered per routeA marketing site with a few dynamic pages
FAQ

Questions about static site generator

Is a static site good for SEO?
Yes. Pages arrive as complete HTML, load fast and are easy to crawl. You still need correct titles, canonicals, sitemaps and structured data.
Can a static site have forms and search?
Yes. Forms post to a form service or serverless function, and search runs client-side from a generated index or through a hosted search API.
Which static site generator is best?
For content and marketing sites we usually pick Astro. The right one depends on your team’s language and the size of your content: Hugo for very large sites, Eleventy or Jekyll for simple ones.
Is Next.js a static site generator?
Partly. Next.js can export static pages, but it is a full framework that also renders on the server, so it suits products more than plain content sites. See Next.js development.
Can marketers edit a static site?
Yes, through a headless CMS: editors work in a normal editor and each published change triggers a rebuild of the site.
Thomas OldenburgerFounder, design and build lead

Still deciding? A 30-minute call answers most of it.

Got a brief, or half of one?

Book a free 30-minute call. You leave with a straight answer on scope, price and timing, even when we are not the right fit.