nextjs - 💡(How to fix) Fix <Link> doesn't work in global-not-found.tsx [2 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
vercel/next.js#88341Fetched 2026-04-08 02:05:02
View on GitHub
Comments
2
Participants
3
Timeline
8
Reactions
1
Timeline (top)
labeled ×3commented ×2closed ×1issue_type_added ×1

Code Example

Operating System:
  Platform: win32
  Arch: x64
  Version: Windows 11 Enterprise
  Available memory (MB): 16069
  Available CPU cores: 20
Binaries:
  Node: 22.19.0
  npm: 10.9.3
  Yarn: N/A
  pnpm: 10.21.0
Relevant Packages:
  next: 16.1.1 // Latest available version is detected (16.1.1).
  eslint-config-next: N/A
  react: 19.2.3
  react-dom: 19.2.3
  typescript: N/A
Next.js Config:
  output: N/A
RAW_BUFFERClick to expand / collapse

Link to the code that reproduces this issue

https://github.com/isaacmaddox/global-not-found-issue

To Reproduce

  1. Start application in dev mode (next dev) OR build and run in production (next build && next start)
  2. Navigate to any page other than / (http://localhost:3000/notfound)
  3. Click the "Go home" link
  4. Nothing happens

Current vs. Expected behavior

Currently, the URL changes in the URL bar but no new page is rendered.

Expected to change URL and render the / route.

Provide environment information

Operating System:
  Platform: win32
  Arch: x64
  Version: Windows 11 Enterprise
  Available memory (MB): 16069
  Available CPU cores: 20
Binaries:
  Node: 22.19.0
  npm: 10.9.3
  Yarn: N/A
  pnpm: 10.21.0
Relevant Packages:
  next: 16.1.1 // Latest available version is detected (16.1.1).
  eslint-config-next: N/A
  react: 19.2.3
  react-dom: 19.2.3
  typescript: N/A
Next.js Config:
  output: N/A

Which area(s) are affected? (Select all that apply)

Linking and Navigating, Loading UI and Streaming

Which stage(s) are affected? (Select all that apply)

next dev (local), next start (local), Vercel (Deployed), Other (Deployed)

Additional context

No response

extent analysis

TL;DR

The issue can likely be resolved by modifying the Link component from next/link to use the replace prop or checking for any conflicting client-side routing configurations.

Guidance

  • Verify if the Link component is being used correctly, specifically checking if the href attribute is set to the correct route ("/") and if any additional props like replace or shallow are being used.
  • Check the Next.js configuration for any custom routing settings that might be interfering with the default client-side routing behavior.
  • Inspect the browser's console for any errors that might occur when clicking the "Go home" link, which could indicate a JavaScript error preventing the navigation.
  • Review the code in the provided GitHub repository to ensure there are no conflicting routing configurations or custom link handling logic.

Example

// Example of using the replace prop with next/link
import Link from 'next/link';

function GoHomeLink() {
  return (
    <Link href="/" replace>
      Go home
    </Link>
  );
}

Notes

The provided information does not include the exact code for the "Go home" link, so the solution might vary depending on how the link is implemented. Additionally, the issue could be related to a specific configuration or version of Next.js, but based on the information given, modifying the Link component or checking for custom routing configurations seems like the most direct path to resolving the issue.

Recommendation

Apply workaround: The safest approach, given the lack of specific code for the "Go home" link, is to try modifying the Link component or checking for conflicting routing configurations, as this does not require upgrading any packages and can be done within the existing codebase.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

nextjs - 💡(How to fix) Fix <Link> doesn't work in global-not-found.tsx [2 comments, 3 participants]