-
-
Notifications
You must be signed in to change notification settings - Fork 769
Description
Environment
Nuxt version: 4.2.1
Vue version: 3.5.25
Nitro version: 2.12.9
Platform: Vercel
ISR: Enabled
Reproduction
Repository: https://github.com/fmoessle/nitro-vercel-isr
Live demo: https://nitro-vercel-isr.vercel.app/
Describe the bug
When using ISR (Incremental Static Regeneration) with Nitro on Vercel, dynamic routes return cached content from the first visited route and redirect the URL back to that first route.
export default defineNuxtConfig({
compatibilityDate: '2025-07-15',
devtools: { enabled: true },
routeRules: {
'/**': {
isr: { allowQuery: [] }
}
}
})Steps to Reproduce
Visit / (or any route like /hello) - page is correctly cached
Visit a different route like /goodbye
The page shows content from step 1 AND the URL changes back to the first visited route
Expected Behavior
Each dynamic route should:
Generate and cache its own content based on the route parameter
Maintain the correct URL in the browser
Not redirect to previously cached routes
Actual Behavior
All routes return the same cached content from the first visited route
The browser URL is changed/redirected back to the first cached route
Subsequent route visits are essentially ignored by the cache mechanism
Additional context
No response