Skip to content
masterclassBuddyTech Buzz5 fresh blogs · 5:00 AM IST

Frontend

What is the difference among SSR, SSG, ISR and Partial Prerendering?

SSG builds HTML once, ISR rebuilds it in the background on a schedule, SSR renders on every request, and Partial Prerendering serves a static shell instantly while dynamic parts stream in.

Technologies
4
Difference questions
50

What each one is

SSG

Static site generation: HTML built at build time.

Fastest and cheapest, served from a CDN; content only changes on rebuild.

ISR

Incremental static regeneration: static pages refreshed after a time or on demand.

Static speed with periodic freshness; in Next.js 16 this is cacheLife and revalidateTag.

SSR

Server-side rendering on every request.

Always fresh and personalised, but each request costs server time.

PPR

Partial Prerendering: a static shell plus streamed dynamic holes.

Next.js 16 Cache Components ships the shell instantly and streams request-time parts inside Suspense.

At a glance

AspectSSGISRSSRPPR
RenderedAt buildAt build + revalidationEvery requestShell at build, holes per request
FreshnessUntil rebuildTime or tag basedAlwaysMixed per component
SpeedFastestFastestSlowerFast shell
PersonalisationNoNoYesYes, in holes

The 10 most-asked difference questions

Subjective questions 10

1What is the difference among SSG, SSR, ISR and Partial Prerendering?Asked almost every time

SSG builds HTML once at build time. SSR renders HTML on every request. ISR serves static HTML and regenerates it in the background after a time or on demand. Partial Prerendering serves a static shell instantly and streams the dynamic parts of the same page per request.

2When should you use SSG?Asked almost every time

For pages whose content is the same for everyone and changes rarely, such as marketing pages, documentation and blog posts. It is the fastest and cheapest option because the CDN serves files.

3When should you use SSR?Asked almost every time

When every request needs fresh or personalised data, such as a dashboard showing the signed-in user's account, a cart or live prices that cannot be cached.

4When should you use ISR?Asked almost every time

When content is mostly static but changes over time, such as product pages or articles. Visitors get static speed, and pages refresh after a time window or when content changes.

5When should you use Partial Prerendering?Asked almost every time

When a page mixes static and personalised parts, such as a product page with a static description and a personalised cart badge or recommendations. The static shell loads instantly and only the dynamic holes wait for the server.

6How does Next.js 16 express these with Cache Components?Very often asked

Pages are prerendered when they use only static or cached data; 'use cache' with cacheLife gives ISR-style revalidation; runtime data such as cookies inside Suspense becomes dynamic streamed content, which together is Partial Prerendering.

7What replaced export const revalidate with Cache Components?Very often asked

cacheLife inside a 'use cache' scope, with built-in profiles like hours or days or custom stale, revalidate and expire values; route segment configs such as revalidate are not allowed when cacheComponents is enabled.

8What is on-demand revalidation?Very often asked

Refreshing cached content when data changes instead of waiting for a timer, using revalidateTag or updateTag with tags set by cacheTag, typically from a Server Action or webhook.

9What is the difference between revalidateTag and updateTag?Very often asked

revalidateTag marks tagged data stale so the next request sees fresh content (stale-while-revalidate). updateTag expires it immediately within a Server Action so the user who made a change sees it right away.

10How does each affect Time to First Byte?Very often asked

SSG, ISR and the PPR shell are served from cache or CDN with very low TTFB. SSR must render before responding, so TTFB depends on data fetching and server speed.

See all 50 difference questions with answers in your dashboard →

Practise every comparison in your dashboard.

Start learning