We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https://github.com/alyustik/nextjs-notfound-regression
Current: global metadata, that was defined in root layout is missing on the non-existing page Expected: global metadata preserves on non-existing page
Operating System: Platform: win32 Arch: x64 Version: Windows 11 Pro Available memory (MB): 64662 Available CPU cores: 16 Binaries: Node: 22.5.1 npm: 10.8.2 Yarn: N/A pnpm: 10.5.2 Relevant Packages: next: 15.3.0-canary.22 // Latest available version is detected (15.3.0-canary.22). eslint-config-next: N/A react: 19.0.0 react-dom: 19.0.0 typescript: 5.8.2 Next.js Config: output: N/A
Not Found, Metadata
next dev (local), next build (local), next start (local)
If it helps, that only happens on pages, where notFound() was invoked. So if I would create directories like
And then I navigate to /non-existing-page - meta would work. But if I navigate to /articles/non-existing-page - meta wouldn't work.
Happens with both generateMetadata() and metadata object.
I also tried to add metadata on not-found.tsx but it was ignored.
Issue can be reproduced starting from 15.2.0
The text was updated successfully, but these errors were encountered:
I can confirm that this doesn't appear to be an issue on 15.1.7. Seems to break, as noted on 15.2.0 and higher.
Sorry, something went wrong.
No branches or pull requests
Link to the code that reproduces this issue
https://github.com/alyustik/nextjs-notfound-regression
To Reproduce
Current vs. Expected behavior
Current: global metadata, that was defined in root layout is missing on the non-existing page
Expected: global metadata preserves on non-existing page
Provide environment information
Which area(s) are affected? (Select all that apply)
Not Found, Metadata
Which stage(s) are affected? (Select all that apply)
next dev (local), next build (local), next start (local)
Additional context
If it helps, that only happens on pages, where notFound() was invoked.
So if I would create directories like
And then I navigate to /non-existing-page - meta would work.
But if I navigate to /articles/non-existing-page - meta wouldn't work.
Happens with both generateMetadata() and metadata object.
I also tried to add metadata on not-found.tsx but it was ignored.
Issue can be reproduced starting from 15.2.0
The text was updated successfully, but these errors were encountered: