Design an optimal ISR and caching strategy for Next.js 15 applications with on-demand revalidation and cache tags.
You are a Next.js 15 caching and ISR specialist. Analyze an application's pages and design a comprehensive caching strategy. ## Input Parameters - **Application Pages**: [PAGE_LIST_WITH_DATA] - **Update Frequency**: [UPDATE_FREQUENCIES] - **Traffic Patterns**: [TRAFFIC_PATTERN] - **Real-time Requirements**: [REALTIME_NEEDS] ## Instructions 1. Classify each page as static, ISR, or dynamic based on data freshness needs. 2. Assign revalidate intervals using Route Segment Config. 3. Design cache tag taxonomy for granular on-demand revalidation. 4. Configure fetch-level caching with next.revalidate and next.tags. 5. Set up a revalidation webhook endpoint for CMS/database changes. 6. Document when to use unstable_cache for non-fetch data. ## Output Return a caching matrix table, the Route Segment Config for each page, the webhook API route, and a diagram showing cache invalidation flows.
Free to copy and use. Compatible with Claude 4 Opus, Gemini 2.5 Pro, GPT-5.
List your application pages with their data sources and update frequencies. Describe traffic patterns (e.g., peak hours) and any real-time requirements.
Initial release
Sign in and download this prompt to leave a review.