Better Auth Setup & Scaffolding
Scaffolds and implements secure authentication workflows in TypeScript and JavaScript applications using Better Auth.
This skill guides and automates the complete setup of authentication in TypeScript and JavaScript web applications using Better Auth. It automatically detects project frameworks, ORMs, and database configurations, plans requirements across sign-in providers and security features, generates server and client configs, handles database migrations, and creates styled authentication UI components for login, registration, password recovery, and multi-factor authentication.
Key Features
01Automates database schema migrations across Prisma, Drizzle, Kysely, and MongoDB
02Configures advanced plugins like 2FA, organization/team management, SSO, and API bearer tokens
030 GitHub stars
04Generates server and client configurations for Next.js, SvelteKit, Nuxt, Astro, and Hono
05Auto-detects frontend frameworks, database ORMs, and existing auth packages
06Supports multiple auth methods including email/password, OAuth, magic links, and passkeys
Use Cases
01Migrating legacy auth setups (NextAuth, Lucia, Clerk) to a self-hosted Better Auth solution
02Scaffolding full-stack authentication from scratch in a new Next.js or SvelteKit project
03Adding OAuth providers (Google, GitHub, Apple) and 2FA into existing web applications