Software Services
For Companies
Products
Build AI Agents
Security
Portfolio
Build With Us
Build With Us
Get Senior Engineers Straight To Your Inbox

Every month we send out our top new engineers in our network who are looking for work, be the first to get informed when top engineers become available

At Slashdev, we connect top-tier software engineers with innovative companies. Our network includes the most talented developers worldwide, carefully vetted to ensure exceptional quality and reliability.
Build With Us
Scaling Next.js for Marketing Sites: SSG, ISR, RSC & Edge/

Scaling Next.js: choosing SSG, ISR, RSC, and Serverless wisely
Planning a Marketing site rebuild with Next.js is less about frameworks and more about choosing the right rendering contract per route. At enterprise scale, that contract determines Core Web Vitals, SEO, deployment risk, and unit economics. Here’s a pragmatic blueprint for when to use SSG, ISR, React Server Components (RSC), and Serverless/Edge, with patterns you can apply today.
When SSG is your unfair advantage
- Use for: evergreen content, landing pages, docs, PR posts, partners, pricing snapshots.
- Why: zero runtime, maximal cacheability, predictable costs, great SEO. Pair with CDN HTML caching and image optimization.
- Watch-outs: long build times with huge catalogs; solve via route-level static generation, parallelized builds, and content sharding by locale or section.
- Operational tip: wire preview mode to your CMS so marketers see exact rendering without shipping runtime logic.
ISR: the middle lane for changing catalogs
- Use for: product detail pages, case studies, blog indexes, campaign hubs that update hourly or daily.
- Why: keep static performance while refreshing on a TTL or webhook. Readers get a cached page; the next request triggers regeneration.
- Key settings: set TTL per template, not globally. Use blocking for SEO-critical routes; use fallback for long tails.
- Scale guardrails: apply concurrency caps to regeneration, warm hotspots via synthetic traffic before launches, and invalidate by tag when datasets change.
RSC and Server Actions: ship less JavaScript, more value
- Use for: data-heavy shells (navigation, filters, personalized modules) where sending zero client JS is a win.
- Why: RSC streams HTML, reduces bundle size, and lets you colocate data fetching on the server. Server Actions simplify mutations without client API plumbing.
- Boundaries: keep analytics and highly interactive widgets as client components; make the rest server-driven with Suspense for perceived speed.
- Caching: leverage per-request caches for user-specific blocks and long-lived caches for public data. Tag invalidations to avoid thundering herds.
Serverless and Edge: compute where it matters
- Use Node serverless for: CPU/IO tasks, payments, image transforms, and SSR that needs libraries not supported at the Edge.
- Use Edge for: geolocation, A/B routing, redirects, and header rewriting. Tiny logic, massive reach.
- Cold starts: mitigate with provisioned concurrency for peak windows and short-lived handlers. Prefer streaming SSR to reduce TTFB.
- Compliance: route PII and regulated workflows to regional serverless targets; keep Edge logic stateless and anonymized.
Decision patterns that don’t break at 10x
Ask three questions per route: How often does content change? How personalized is it? What’s the business blast radius if it’s stale for N minutes? From there:

- Static, rare updates, broad reach → SSG.
- Frequent updates, predictable staleness tolerance → ISR with webhooks and tags.
- Heavy data + need to minimize JS → RSC for shells; client islands for interactivity.
- Per-request logic, auth, geo, or experiments → Serverless/Edge + streaming.
Three field-tested architectures
- Global marketing site at 30k pages, 12 locales: SSG the evergreen core; ISR campaign hubs at 60s TTL; RSC for nav and footers; Edge locale routing; tag invalidation on CMS publish. Result: 98+ Lighthouse, sub-100ms TTFB globally, builds under 8 minutes via sectioned pipelines.
- Ecommerce with flash sales: ISR product pages keyed by price and stock; serverless checkout with idempotency keys; Edge A/B for hero variants; queue-driven webhooks to throttle regeneration under load. Result: stable carts during spikes, accurate SEO metadata within minutes.
- AI knowledge hub with LLM orchestration and observability: SSG reference docs; RSC + Server Actions to call orchestrators; stream tokens to clients; OpenTelemetry traces from prompts to model outputs; sensitive fields redacted at the Edge. Result: tiny bundles, debuggable inference paths, compliant data flow.
Operations and observability that scale
- Preview parity: one preview stack mirroring production caches and features.
- Build budgets: enforce max build time and static page counts per pipeline chunk.
- Cache strategy: HTML at CDN, API at origin with SWR, image/CDN variants prewarmed for top routes.
- Telemetry: traces across build, ISR revalidate, RSC fetches, and serverless handlers. Alert on revalidation failures and cache hit-rate drops.
Team topology and outsourcing
Codify route-by-route rendering choices in the repo (e.g., /routes.md) and lint them. Use a monorepo with typed CMS clients, contract tests for ISR tags, and synthetic checks for geo logic. If you leverage software engineering outsourcing, choose partners fluent in these patterns; firms like slashdev.io provide senior remote engineers who understand Next.js tradeoffs and can land complex migrations without regressions.
Migration and cost
- Pilot a high-traffic section first; measure before/after TTFB, INP, crawl stats, and revenue per visit.
- Flip routes gradually: start SSG, layer ISR where content proves dynamic, then introduce RSC for weight reduction.
- Cost model: pages × update frequency × cache hit rate. Optimize to push more traffic to static caches, and stream the rest.
Great Next.js architecture is deliberate, not doctrinal. Pick the lightest rendering mode that meets freshness and personalization needs, default to caches, instrument everything, and let marketing move at the speed of ideas without surprising operations or finance.


