Skip to main content
GoodFirstPicks
DashboardIssuesReposLeaderboard

GoodFirstPicks by Leaveitblank © 2026

CreatorRequest a RepoPrivacy PolicyTerms of Service
[Next.js 16] [App Router] searchParams empty on statically generated pages when Draft Mode is enabled (Vercel only) | GoodFirstPicks

[Next.js 16] [App Router] searchParams empty on statically generated pages when Draft Mode is enabled (Vercel only)

vercel/next.js 1 comments 5d ago
View on GitHub
mediumopenScope: somewhat clearSkill match: maybeNext.jsTypeScriptReact

Why this is a good first issue

Issue involves Draft Mode behavior specific to Vercel deployments.

AI Summary

The issue describes a problem where `searchParams` are empty on statically generated pages when Draft Mode is enabled, but only on Vercel deployments. The expected behavior is for `searchParams` to be accessible in Draft Mode, as it works locally and in Next.js 15. The fix likely requires understanding Draft Mode internals and Vercel's deployment behavior.

Issue Description

Link to the code that reproduces this issue

https://github.com/illiakovalenko/app-router-draft-mode-proxy-bug

To Reproduce

  1. Deploy application to Vercel
  2. Visit <host>/api/render url

Current vs. Expected behavior

Current behaviour

I followed the documentation for draftMode and want to pass search parameters via redirect and access them on the page after I hit the route handler: https://nextjs.org/docs/app/guides/draft-mode#step-2-access-the-route-handler-from-your-headless-cms

On Next.js App Router v16 deployed to Vercel, searchParams are empty on a statically generated page, even when Draft Mode is enabled. The same setup works correctly on Next.js 15. This issue does not occur locally with next dev or next start - it only happens on Vercel production deployments.

The route handler redirects to: /test?language=en&timestamp=1775717500894

Image

Expected behaviour

When Draft Mode is enabled, the page should receive the full searchParams object, even if the route is statically generated. This allows the page to remain static (SSG) for normal traffic while switching to dynamic preview behavior in Draft Mode.

Image

Provide environment information

Operating System:
  Platform: win32
  Arch: x64
  Version: Windows 11 Enterprise
  Available memory (MB): 32213
  Available CPU cores: 16
Binaries:
  Node: 22.22.0
  npm: 10.9.4
  Yarn: 4.12.0
  pnpm: 10.33.0
Relevant Packages:
  next: 16.2.1-canary.29 // Latest available version is detected (16.2.1-canary.29).
  eslint-config-next: N/A
  react: 19.2.4
  react-dom: 19.2.4
  typescript: 5.9.3
Next.js Config:
  output: N/A

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

Draft Mode, Dynamic Routes

Which s

GitHub Labels

Dynamic RoutesDraft Mode

Want to work on this?

Claim this issue to let others know you're working on it. You'll earn 20 points when you complete it!

Risk Flags

  • Vercel-specific behavior
  • Draft Mode edge case
Loading labels...

Details

Points20 pts
Difficultymedium
Scopesomewhat clear
Skill Matchmaybe
Test Focusedno