Static Site Generation (SSG)

Rendered via Build-time

Location: New York City, NY

Temperature: 3°C

Wind Speed: 7.4 km/h

Rendered at: 2025-11-19T12:24:29.399Z

Static Site Generation (SSG)

Pages are pre-rendered at build time and served as static HTML. This is the fastest option as pages are generated once and cached on the CDN.

Pros

  • Fastest page loads - served directly from CDN
  • Best SEO - content is immediately available
  • Reduced server load - no runtime computation
  • Highly scalable - can handle massive traffic

Cons

  • Content is stale until next build
  • Build time increases with page count
  • Not suitable for frequently changing data
  • Requires rebuild to update content

Performance Metrics

Server Duration

418.81ms

TTFB

measuring...

DOM Ready

measuring...

Full Load

measuring...

Server Duration: Time to render on server (SSG at build, SSR/ISR/Edge per request)

TTFB: Time to First Byte from browser perspective (network + server time)

DOM/Full Load: Browser-side parsing and resource loading times

Implementation Code

File:app/ssg/page.tsx
export const revalidate = false;

export default async function Page() {
  const data = await fetchData();
  return <DataCard data={data} />;
}

Key Configuration:

  • revalidate = false disables revalidation, making this pure static generation
  • Page is built once during deployment and never regenerated
  • fetchData() runs at build time, not on user requests