luciavsnext-auth
Lucia is session-based, framework-agnostic, gives you full control. NextAuth is OAuth-first with provider configs baked in. Use Lucia if you want to own auth completely.
lucia
github.com/lucia-auth/luciaNote: Lucia announced deprecation in 2024 — the maintainer is sunsetting it in favor of writing your own. Still useful as a learning reference for session-based auth patterns in TypeScript. Better Auth picks up where Lucia left off.
Full review →next-auth
github.com/nextauthjs/next-authThe OG Next.js auth library, now Auth.js. ~24k stars. Quick to add OAuth providers (80+ preconfigured). Best for fast MVP work where you mostly need social login. Less flexible than Better Auth for advanced flows.
Full review →Which should you pick?
Pick lucia if…
You want to learn how session-based auth works from a clean codebase before building your own.
Skip lucia if…
You are picking auth for a new production app — use Better Auth or Auth.js instead.
Pick next-auth if…
You are shipping a Next.js MVP fast and need social login (Google, GitHub) working in an hour.
Skip next-auth if…
You need fine-grained control over sessions, multi-tenant logic, or organization roles — pick Better Auth.
Still picking? Get the full curated stack.
StackPicks members get 100+ open-source tools with curator takes, 13 ready-to-ship stack bundles, and 12 skill tracks. ₹99 lifetime.
See pricing