Lucia Auth

Authentication for Next.js, Astro, SvelteKit, and more.

Visit Website

Lucia Auth is a self-hosted open source solution for authentication with Next.js, Astro, SvelteKit, or Express.js applications.

Use Lucia to manage user sessions as well as user information. You will need a database to store this data, and Lucia has integrations with common databases like MongoDB, PostgreSQL, and SQLite - as well as with the Drizzle and Prisma ORM libraries.

While there are many authentication solutions available for Node.js applications, Lucia Auth also works with Bun, Deno, and Cloudflare Workers.

Similar to other authentication solutions, Lucia Auth supports three different types of authentication:

  1. Credentials - Email (or username) and password
  2. OAuth - Sign in with Google, Facebook, GitHub, etc.
  3. Passkeys - WebAuthn

Generally speaking, you might compare Lucia Auth to other self-hosted solutions like Auth.js.