The hook has been stabilized and a warning will be emitted if the setting is set: https://github.com/vercel/next.js/pull/68853 I spotted some env var `process.env.__NEXT_VERSION` in the Next.js repo. Maybe we can use that to get the version: https://github.com/lforst/nextjs-fork/blob/06c5ea4f16a1ea0eeef0c76c89154e328d6a3faa/packages/next/src/build/index.ts#L718