Visual Guide · Framework Support

It runs on everything.

One auth library. Twenty-plus frameworks. The same five lines of glue everywhere.

§ 01 — Mental Picture

One core, many wrappers.

Framework-agnostic by design
mindmap
  root)Better-Auth(
    Full-Stack
      ::icon(fa fa-cube)
      Next.js
      TanStack Start
      React Router 7
      SvelteKit
      Nuxt
      Astro
      SolidStart
      Waku
    Backend
      ::icon(fa fa-server)
      Express
      Hono
      Fastify
      Elysia
      NestJS
      Nitro
    Platform
      ::icon(fa fa-mobile)
      Electron
      Expo
      Convex
      Encore
      Lynx
        
§ 02 — The Full Roster

Twenty supported, by name.

Full-Stack & Meta Frameworks
8 supported
TanStack Start
your stack
Next.js
App + Pages
React Router 7
ex-Remix
SvelteKit
Svelte
Nuxt
Vue
Astro
SSG + dynamic
SolidStart
SolidJS
Waku
minimal RSC
Backend & API Frameworks
6 supported
Hono
edge / web
Express
Node.js classic
Fastify
high perf
Elysia
Bun-native
NestJS
enterprise
Nitro
universal
Platforms & Runtimes
5 supported
Expo
React Native
Electron
desktop
Convex
BaaS
Encore
TS backend
Lynx
cross-platform
§ 03 — Databases & ORMs

Bring your own data layer.

Native Database & ORM Adapters
7 + generic
PostgreSQL
your pick
MySQL
relational
SQLite
embedded
MS SQL
enterprise
MongoDB
document
Drizzle
ORM
Prisma
ORM
§ 04 — Same Glue, Every Framework

Look at all four. Spot the difference.

TanStack Start your stack
import { createAPIFileRoute }
  from '@tanstack/start/api'
import { auth } from '~/lib/auth'

export const Route = createAPIFileRoute(
  '/api/auth/$'
)({
  GET:  ({ request }) => auth.handler(request),
  POST: ({ request }) => auth.handler(request),
})
Next.js App Router
import { auth } from '@/lib/auth'
import { toNextJsHandler }
  from 'better-auth/next-js'

export const { GET, POST } =
  toNextJsHandler(auth.handler)

// app/api/auth/[...all]/route.ts
Hono edge
import { Hono } from 'hono'
import { auth } from './lib/auth'

const app = new Hono()

app.on(['POST', 'GET'],
  '/api/auth/*',
  (c) => auth.handler(c.req.raw)
)
Express Node.js
import express from 'express'
import { auth } from './lib/auth'
import { toNodeHandler }
  from 'better-auth/node'

const app = express()
app.all('/api/auth/*',
  toNodeHandler(auth)
)
notice
Every one of these is 5–8 lines. The only thing that changes is how the framework declares a route.
§ 05 — Switching Frameworks Later

Five lines change. Everything else stays.

What changes
Route file
What changes
UI components
⇄
Stays the same
auth.ts config
Stays the same
DB schema
Stays the same
User pool
Stays the same
Sessions
Site #14 needs Astro? Site #22 needs Hono on the edge? Same auth. Rewrite ~5 lines and ship.
§ 06 — At a Glance

The breadth, in numbers.

19+
Frameworks &
platforms
7+
Databases &
ORMs
~5lines
Glue code per
framework
0
Vendor or framework
lock-in
Pick the framework. Keep the auth.
One library. Every stack. No rewrites later.