DocsQuick Start2 / 10
Quick Start
Get the template running on your machine in under 5 minutes.
⚡ 5-Minute Setup
Follow these 5 steps to go from zero to running dev server. Don't skip the environment variables step — your app won't start without them.
- 01
Clone the Repository
Download the template to your machine.
bash# Option A — Clone via Git git clone <repository-url> cd auth-setup # Option B — Use as GitHub Template # Click "Use this template" on the repo page, # then clone YOUR copy. - 02
Install Dependencies
Install all required packages with npm.
bashnpm installThis installs Next.js, BetterAuth, Prisma, Tailwind CSS and everything else listed in package.json.
- 03
Create the Environment File
Copy the example file to create your local config.
bashcp .env.example .env.localThen open .env.local and fill in your values. See the Environment Variables section for details.
- 04
Run Database Migrations
Create all the database tables required by BetterAuth.
bashnpx prisma migrate deploy # Or if you want to create fresh migrations: npx prisma generate - 05
Start the Development Server
Launch the app on localhost.
bashnpm run devVisit http://localhost:3000 in your browser. You should see the landing page.
✅ You're running!
The app is live at
http://localhost:3000. Next, configure your environment variables so OAuth and the database connect properly.