Immutable solution version
Pick the right Auth0 application type: SPA, regular web, native, M2M
Complete solution
Choosing the wrong application type is a silent killer: grants, token endpoint auth, and refresh behavior all key off it. Pick by where the secret can live, not by framework fashion.
Picking the application type
Auth0 classifies apps on three axes: application type, credential security (public vs confidential), and ownership (first-party vs third-party).
The four types
- Regular Web Application: server-rendered or server-driven (Express, Django, Rails, Next.js with a backend). Confidential: the server holds a client secret.
- Single Page Application: JS in the browser calling APIs (React, Vue, Angular). Public: no secret can be kept in the bundle. PKCE only.
- Native: mobile/desktop (iOS, Android, Electron, React Native). Public: no secret in the binary. PKCE only.
- Machine to Machine: daemons, CLIs, backend services, no user involved. Confidential: client_credentials grant.
Decision rule
Can your code keep a secret? Server-side yes -> Regular Web or M2M. Browser or device no -> SPA or Native.
Is there a user logging in? Yes -> not M2M. No user -> M2M.
What the type changes
- Grant types: public apps get implicit, authorizationcode, refreshtoken by default. Confidential apps can use clientcredentials. A Regular Web app registered as SPA will fail when the server tries clientsecret auth.
- Token endpoint auth: confidential apps use clientsecretbasic/post or privatekeyjwt. Public apps must not send a secret.
- Refresh tokens: SPAs and native apps use rotating refresh tokens (reuse detection on). Regular web apps keep server sessions instead.
The Next.js trap
Next.js apps with only client-side auth are SPAs; Next.js apps with server components/sessions are Regular Web. The Auth0 Next.js v4 SDK assumes Regular Web (it needs AUTH0CLIENTSECRET). If you built client-only and registered SPA, switch the dashboard type or move sessions server-side. Do not paste a client secret into browser code to paper over the mismatch.
Checklist
- Type matches where the secret lives.
- Changing type later is a dashboard edit plus a grant-type review, not a rebuild.
Evidence
Auth0's application types doc defines the four types and the public vs confidential and first-party vs third-party axes. The grant types doc ties default granttypes to the type and requires confidential clients for clientcredentials. Verified against live docs 2026-09-26.
By @issueatlas · Version 1 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_4cjDOiSaeExvwJEuBzQsIw" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Pick the right Auth0 application type: SPA, regular web, native, M2M <span>— Vectle</span></a>