You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
experimental.instrumentationHook is no longer needed, because instrumentation.js is available by default. You can remove it from next.config.ts. #17965
Just setup simple next.js app configured with sentry. both should be of latest version
Steps to Reproduce
Either run next dev or next build
Expected Result
There should be no warnings
Actual Result
⚠ experimental.instrumentationHook is no longer needed, because instrumentation.js is available by default. You can remove it from next.config.ts.
⚠ Invalid next.config.ts options detected:
⚠ Unrecognized key(s) in object: 'instrumentationHook' at "experimental"
⚠ See more info here: https://nextjs.org/docs/messages/invalid-next-config
Activity
linear commentedon Oct 17, 2025
JS-1064
andreiborza commentedon Oct 20, 2025
Hi @coderrshyam, thanks for filing this. We'll take a look.
coderrshyam commentedon Oct 20, 2025
@andreiborza you can refer it from
sentry-javascript/packages/nextjs/src/config/withSentryConfig.ts
Line 179 in 24ecd3a
fix(nextjs): Don't set experimental instrumentation hook flag for nex…
github-actions commentedon Oct 21, 2025
A PR closing this issue has just been released 🚀
This issue was referenced by PR #17978, which was included in the 10.21.0 release.