unstale

npm / @auth0/nextjs-auth0

@auth0/nextjs-auth0

What changed in @auth0/nextjs-auth0 4, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-17.

5 breaking17 security41 new APIs and options40 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli 0.1.0 on npm

@auth0/nextjs-auth0 4103 changes

Breaking changes 5

  • Session expiry errors are surfaced instead of being silently handled by session rotation.

    4.31.1release notes

  • Transaction cookies now include a timestamp prefix, creating a bounded rolling-deployment incompatibility window between v4.29.0 and v4.28.0.

    4.29.0release notes

  • Enterprise connections now enforce an IPSIE session_expiry ceiling.

    4.24.0release notes

  • Unintended class and type exports were removed from the SDK.

    4.14.1release notes

  • TokenRequestCache is removed when calling getAccessToken, changing how access-token requests are handled.

    4.11.2release notes

Security 17

  • createRouteUrl prevents open redirects by checking for cross-origin origins.

    4.32.0release notes

  • The request cookies are passed so stale transaction cookies can be evicted during enterprise login.

    4.31.1release notes

  • Updated Next.js to patched versions to address security vulnerabilities.

    4.28.0release notes

  • Insecure issuer URLs now preserve their ports.

    4.26.0release notes

  • Magic-link transactions now generate and store a nonce for ID token flows.

    4.26.0release notes

  • Refresh tokens are now revoked on logout.

    4.26.0release notes

  • Refresh tokens are revoked on logout in mTLS flows.

    4.23.1release notes

  • Per-request max_age is persisted in TransactionState to enforce auth-related behavior.

    4.23.1release notes

  • Deleted cookies now include Secure, SameSite, and HttpOnly attributes in Set-Cookie.

    4.21.0release notes

  • Logout now deletes the v3 appSession cookie.

    4.20.0release notes

  • Stale session reuse during proxy DPoP nonce retries was fixed.

    4.20.0release notes

  • Auth0 Next.js SDK has Improper Proxy Cache Lookup

    4.18.0security advisory

  • Updated Next.js peer dependencies to address CVE-2025-55184 and CVE-2025-55183.

    4.13.3release notes

  • Improper Validation of Query Parameters in Auth0 Next.js SDK

    4.13.0security advisory

  • Prevents OAuth parameter injection through returnTo.

    4.13.0release notes

  • Improper Request Caching Lookup in the Auth0 Next.js SDK

    4.11.2, 4.12.1security advisory

  • Connected Accounts use fetcher so DPoP is used properly.

    4.11.0release notes

New APIs and options 41

  • The package now ships agent skills for use with the technology.

    4.31.1release notes

  • Adds anonymous sessions with Session Transfer Ticket linking, available as an EA feature.

    4.31.0release notes

  • Added Enterprise Connect support for enterprise SSO flows.

    4.30.0release notes

  • Added typed parameters for selecting login experiments and variations.

    4.30.0release notes

  • Added route support for federated-domain checks.

    4.30.0release notes

  • Added federated-domain detection and login helpers.

    4.30.0release notes

  • Added support for listing and disconnecting connected accounts, including cleanup of orphaned cookies.

    4.28.0release notes

  • Added an optional login hint for connection token flows.

    4.28.0release notes

  • Session user data now exposes the optional My Organization permissions claim for use in application interfaces and UI authorization.

    4.27.0release notes

  • Added an API for revoking refresh tokens.

    4.26.0release notes

  • Added session transfer token support for CTE workflows.

    4.26.0release notes

  • Adds a passwordless database implementation for applications using Auth0 authentication.

    4.25.0release notes

  • CTE delegation was added.

    4.23.0release notes

  • MtlsError and MtlsErrorCode were added for handling Mutual TLS authentication errors.

    4.23.0release notes

  • Mutual TLS authentication support was added to the AuthClient and Auth0Client public API.

    4.23.0release notes

  • A predicate function parameter was added to allow selectively rolling sessions.

    4.23.0release notes

  • The auth0-client header can now be allow-listed for forwarding.

    4.21.0release notes

  • AuthorizationParameters now accepts connection for passwordless authentication flows.

    4.21.0release notes

  • AuthorizationParameters now accepts login_hint for passwordless authentication flows.

    4.21.0release notes

  • Error classes and types were added for passwordless authentication.

    4.21.0release notes

  • Next.js route handlers were added for passwordless authentication flows.

    4.21.0release notes

  • AuthClient now provides passwordlessStart for initiating passwordless authentication.

    4.21.0release notes

  • AuthClient now provides passwordlessVerify for completing passwordless authentication.

    4.21.0release notes

  • AuthorizationParameters now accepts screen_hint for passwordless authentication flows.

    4.21.0release notes

  • Access token routes can now be customized.

    4.20.0release notes

  • Profile routes can now be customized.

    4.20.0release notes

  • Adds reactive MFA step-up via Universal Login using a popup.

    4.19.0release notes

  • SessionDataStore now supports an optional update() method for updating session data.

    4.18.0release notes

  • Added support for multiple custom domains.

    4.17.0release notes

  • Adds support for dynamically determining the application base URL.

    4.16.0release notes

  • Adds an allow list for dynamic APP_BASE_URL configuration.

    4.16.0release notes

  • Adds an option for refreshing access tokens early.

    4.16.0release notes

  • The access-token endpoint now supports TTL and optionally returns the full client response.

    4.15.0release notes

  • MFA APIs were added, enabling developers to integrate multi-factor authentication capabilities.

    4.15.0release notes

  • Base MFA support was added for applications using the SDK.

    4.15.0release notes

  • Adds custom token exchange support for applications using the SDK.

    4.14.0release notes

  • Connected accounts now support the scopes parameter.

    4.13.0release notes

  • Adds Proxy handler support, enabling My Account and My Org.

    4.12.0release notes

  • Adds support for access tokens with different audiences through MRRT.

    4.11.0release notes

  • Adds support for connected accounts.

    4.11.0release notes

  • Adds support for Demonstrating Proof-of-Possession.

    4.11.0release notes

Fixes and other changes 40

  • Channel factor names are mapped to oob in mfaChallenge, correcting MFA challenge behavior.

    4.32.1release notes

  • Cookie attributes are preserved when refreshing from a Server Action.

    4.32.0release notes

  • The /me and /my-org endpoints return 401 instead of 500 when token refresh fails.

    4.32.0release notes

  • Middleware is now bound to the Auth0Client instance, fixing instance context issues.

    4.30.0release notes

  • Login-link prefetching was improved to avoid triggering unintended login flows.

    4.29.0release notes

  • Proxy URL construction now preserves query parameters that contain multiple values.

    4.29.0release notes

  • Transaction cookies now use FIFO eviction with a 3500-byte total size cap, preventing unbounded accumulation and 431 errors.

    4.29.0release notes

  • The state parameter is forwarded to the OIDC end-session URL during logout.

    4.23.1release notes

  • Interactive flow routing is corrected for mTLS.

    4.23.1release notes

  • Path-based issuer URLs no longer receive an added trailing slash.

    4.23.0release notes

  • MfaRequiredError is now surfaced from passkeyGetToken and passwordless verification flows.

    4.23.0release notes

  • Allows path-based domain URLs when using Okta custom authorization servers.

    4.22.0release notes

  • Domain validation now respects the allowInsecureRequests option.

    4.20.0release notes

  • Fixes MFA HTTP contract parity issues.

    4.19.0release notes

  • Skips MCD session backfill when running in static mode.

    4.19.0release notes

  • Fixed a race issue affecting DPoP nonce retries.

    4.18.0release notes

  • Construction is deferred when AUTH0_DOMAIN is not set at build time, preventing build-time failures.

    4.17.1release notes

  • Fixes a Next.js edge runtime build error involving the crypto module.

    4.17.1release notes

  • Prevents rolling sessions from re-creating a deleted session during concurrent logout.

    4.17.0release notes

  • Error details from HTTP 5xx OAuth responses are preserved.

    4.16.2release notes

  • Middleware no longer throws ERR_JWE_INVALID.

    4.16.2release notes

  • Made withPageAuthRequired generic to support PageProps and LayoutProps types.

    4.16.1release notes

  • Enabled full generic type inference so PageProps and LayoutProps propagate correctly.

    4.16.1release notes

  • Falsey values in authorization parameters are preserved instead of being stripped.

    4.16.0release notes

  • The SDK catches ERR_JWE_DECRYPTION_FAILED and ignores the cookie instead of throwing.

    4.14.1release notes

  • Using getAccessToken with refresh no longer causes a headers.append error in Next.js 16 proxy.

    4.14.1release notes

  • Fixed session writes for the Pages Router when using chunked cookies.

    4.13.3release notes

  • Updated the supported Next.js peer dependency versions.

    4.13.2release notes

  • Updated the supported React peer dependency versions.

    4.13.2release notes

  • Updated the supported React-DOM peer dependency versions.

    4.13.2release notes

  • Fixed broken Next.js 16 applications when basePath is used.

    4.13.1release notes

  • Adds support for Next 16.

    4.13.0release notes

  • Session changes are merged before finalizing the session after refresh.

    4.13.0release notes

  • TokenRequestCache is removed when calling getAccessToken.

    4.12.1release notes

  • The hook now receives the updated token after a token refresh.

    4.11.1release notes

  • Auth code callbacks now retry when a DPoP nonce is required.

    4.11.1release notes

  • Server helpers no longer depend on React, fixing bundling for edge runtimes.

    4.11.1release notes

  • Fixes updateSession behavior and related header overwrite issues.

    4.11.1release notes

  • with-next-intl now appends internationalization headers instead of overwriting existing headers.

    4.11.1release notes

  • The fetcher now honors token_type.

    4.11.0release notes