Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/nextjs
SDK Version
10.20.0
Framework Version
React@19.2.0 and Next@16.0.0-beta.0
Link to Sentry event
No response
Reproduction Example/SDK Setup
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
▲ Next.js 16.0.0-canary.10 (Turbopack)
- Environments: .env.local
- Experiments (use with caution):
✓ browserDebugInfoInTerminal
· clientTraceMetadata
? instrumentationHook (invalid experimental key)
· optimizePackageImports
✓ turbopackFileSystemCacheForDev
Additional Context
Next config code:
import { withSentryConfig } from "@sentry/nextjs";
import { createMDX } from "fumadocs-mdx/next";
import type { NextConfig } from "next";
const nextConfig: NextConfig = {
reactCompiler: true,
reactStrictMode: true,
typedRoutes: true,
transpilePackages: [
"@react-email/components",
"@react-three/drei",
"@react-three/fiber",
"three",
"sonner",
],
experimental: {
clientSegmentCache: true,
browserDebugInfoInTerminal: true,
turbopackFileSystemCacheForDev: true,
optimizePackageImports: [
"@react-email/components",
"@react-three/drei",
"@react-three/fiber",
"three",
"three-globe",
"motion",
],
},
};
const withMDX = createMDX();
const sentryConfig = {
org: process.env.SENTRY_ORG,
project: process.env.SENTRY_PROJECT,
disableLogger: true,
silent: !process.env.CI,
tunnelRoute: "/monitoring",
automaticVercelMonitors: true,
widenClientFileUpload: true,
};
export default withSentryConfig(withMDX(nextConfig), sentryConfig);
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/nextjs
SDK Version
10.20.0
Framework Version
React@19.2.0 and Next@16.0.0-beta.0
Link to Sentry event
No response
Reproduction Example/SDK Setup
Just setup simple next.js app configured with sentry. both should be of latest version
Steps to Reproduce
Either run
next devornext buildExpected Result
There should be no warnings
Actual Result
⚠
experimental.instrumentationHookis no longer needed, becauseinstrumentation.jsis 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
Additional Context
Next config code: