Next.js Discord

Discord Forum

Not Found Page Not Working on Vercel Deployment (Next.js 14)

Unanswered
Giant Angora posted this in #help-forum
Open in Discord
Giant AngoraOP
project/
├── app/
│ ├── [lang]/ // Dynamic folder for different languages
│ │ ├── [regular]/ // Contains regular pages for each language (e.g., about.tsx, contact.tsx)
│ │ │ └── page.tsx // (Optional) Can be used as a default layout for regular pages in this language.
│ │ └── [...notfound]/ // Catch-all route for unmatched routes within the language folder.

I'm encountering an issue where the Not Found page in my Next.js project works correctly during local development (yarn build) but not on Vercel deployment. The route en/hssh should trigger the Not Found page, but it doesn't seem to be working as expected.

Troubleshooting Steps Taken:
- Rebuilt and redeployed the project to Vercel.
- Checked Vercel build logs for errors or warnings.
- Reviewed catch-all routes and dynamic routes in Next.js configuration.

Has anyone else faced this issue? Any suggestions or insights would be greatly appreciated!

Additional Information:

- GitHub Repository: https://github.com/tfmukles/nextplate

19 Replies

interesting set up
why not use not-found.tsx?
Giant AngoraOP
I need multi language not-found page.
possible
@ᴉuɐpɹɐɐ possible
Giant AngoraOP
I think with catch all route possible
ok i will try it first and get back to you
Giant AngoraOP
it's work on local build as expected but on the vercel deployment return 500 status
500 seems like its not a not-found issue
Giant AngoraOP
what about the log/error message
Giant AngoraOP
it's gives 500 error
[HEAD] /_next/data/MTzMqYL0j-QyBRDio6K05/en/hhh.json?nxtPlang=en&nxtPnotfound=hhh status=500
scroll down?
Giant AngoraOP
Giant AngoraOP
@ᴉuɐpɹɐɐ do you find any solution?