Errors

NUXT_AUTH_CLI_VERSION_MISMATCH: Better Auth CLI version does not match better-auth

Align auth and better-auth so the app resolves one copy of Better Auth.
Example error
[NUXT_AUTH_CLI_VERSION_MISMATCH] auth@1.7.11 installs better-auth@1.7.11, but this app uses better-auth@1.7.3. Two copies of Better Auth cause conflicting types.

Why this happens

The auth package depends on an exact better-auth version. When it differs from the better-auth version in your app, the package manager installs both, along with two copies of @better-auth/core. Better Auth plugins such as @better-auth/oauth-provider can then resolve a different core than better-auth, and TypeScript reports errors such as a string not being assignable to never.

How to fix it

Run pnpm add -D auth@1.7.3 so auth and better-auth use the same version.

Install auth at the version of better-auth your app uses:

pnpm add -D auth@1.7.3

Alternatively, upgrade better-auth and auth together to the same newer version.

Verify the fix

Run pnpm exec nuxt prepare. The warning should no longer appear, and pnpm why better-auth should list a single version.

See Set up NuxtHub or return to the error reference.