Incremental Static Regeneration (ISR)
ISR allows static pages to update automatically after deployment without rebuilding the entire site.
What is ISR?
ISR combines static generation with background updates. Pages are pre-built, but refreshed periodically when new requests arrive.
How does it work?
fetch("API", {
next: { revalidate: 10 }
});The first request uses cached static content. After the revalidation time passes, Next.js regenerates the page in the background.
Why use ISR?
- Fast static performance
- Automatic content freshness
- No full rebuild needed
- Scales well
Real-World Example
An e-commerce product page updates prices every few minutes without redeploying the site.
Interview Tip
ISR allows static pages to regenerate in the background after a set interval, combining performance with fresh data.
- sunt aut facere repellat provident occaecati excepturi optio reprehenderit
- qui est esse
- ea molestias quasi exercitationem repellat qui ipsa sit aut