-
Notifications
You must be signed in to change notification settings - Fork 29.9k
Open
Labels
Linking and NavigatingRelated to Next.js linking (e.g., <Link>) and navigation.Related to Next.js linking (e.g., <Link>) and navigation.Loading UI and StreamingRelated to loading UI (loading.tsx) and streaming.Related to loading UI (loading.tsx) and streaming.
Description
Link to the code that reproduces this issue
https://github.com/jperezr21/next-16-issue
Problem
On the home page, the navigation bar contains links to various pages, with the first link being /c/brands. When the home page loads, multiple prefetch requests are triggered for /c/brands?_rsc=, which can take more than 5 seconds to complete. If a user clicks the brands link before the prefetch request completes, navigation is blocked until the prefetch request finishes, resulting in a poor user experience.
Reproduction Steps
- Build the application:
pnpm build - Start production server:
pnpm start - Navigate to home page (
/) - Open browser DevTools Network tab
- Filter for requests containing
_rsc= - Observe multiple prefetch requests for
/c/brands?_rsc= - Click the brands link before prefetch completes
- Notice navigation is delayed until prefetch finishes
Current vs. Expected behavior
Expected Behavior
- Links should be prefetched once when they enter the viewport or on hover
- Navigation should be immediate when a user clicks a link, regardless of prefetch status
- Prefetch requests should not block user navigation
Actual Behavior
- Multiple prefetch requests are triggered for the same route (e.g.,
/c/brands?_rsc=) - Prefetch requests can take 5+ seconds to complete
- Clicking a link before prefetch completes blocks navigation until prefetch finishes
- This creates a noticeable delay and poor UX
Provide environment information
Operating System:
Platform: win32
Arch: x64
Version: Windows 10 Pro
Available memory (MB): 16043
Available CPU cores: 8
Binaries:
Node: 22.16.0
npm: 10.9.2
Yarn: 1.22.22
pnpm: N/A
Relevant Packages:
next: 16.0.3 // Latest available version is detected (16.0.3).
eslint-config-next: N/A
react: 19.2.0
react-dom: 19.2.0
typescript: 5.8.3
Next.js Config:
output: standaloneWhich area(s) are affected? (Select all that apply)
Linking and Navigating, Partial Prerendering (PPR), Loading UI and Streaming
Which stage(s) are affected? (Select all that apply)
next build (local)
Additional context
- This issue was identified after upgrading from Next.js 15 to 16
- The issue affects both local production builds (
next start) and Vercel deployments - The problem is more noticeable on slower network connections
- The brands page (
/c/brands) is particularly affected due to its complexity and data requirements
O4epegb
Metadata
Metadata
Assignees
Labels
Linking and NavigatingRelated to Next.js linking (e.g., <Link>) and navigation.Related to Next.js linking (e.g., <Link>) and navigation.Loading UI and StreamingRelated to loading UI (loading.tsx) and streaming.Related to loading UI (loading.tsx) and streaming.