A decorative background image
next-auth-template

Sign up and auth, super quick

With database-backed sessions, social sign in, and magic links.

Features

Custom sign in and sign up pages
Simple, interactive-rich, and server action-backed
Database-backed sessions
Not using Postgresql? Drizzle lets you use any db
Google Sign-in ready for config
Easily add more via nextauth.js
Magic Links via Resend ready for config
Or use any other email providers
Basic account creation and set up
A pre-built account setup page ready to build on
Protected paths via middleware
Easily protect app routes with auth middleware

See all the features and how to use them in the documentation

Core Dependencies

Required to make the basics work. They could be replaced, but it would defeat the point of this template.

  • next
  • next-auth
  • react
  • drizzle-orm
  • zod
  • @neondatabase/serverless

Other Dependencies

Adds a bit of style or utility, could easily be replaced.

  • shadcn/ui
  • tailwindcss
  • @radix-ui
  • lucide-react

See the full list of dependencies in package.json