Quick Start
I have designed this guide to walk you through every step of the setup process. From preparing your local machine to deploying your first admin user, this page covers the essential foundation of SaaS Box.
Prerequisites
Ensure your machine is equipped with these core tools before you begin.
The fundamental runtime required to execute the Next.js 16 server and build scripts.
I use PNPM for workspace management. To install it globally, run:
Essential for version control and pulling future updates from the private SaaS Box repository.
1. Access & Installation
SaaS Box is a premium boilerplate. You can only clone the repository after having purchased a license via Gumroad . Once you have access to the private repository, clone the project and install the dependencies.
2. Configure Environment
I have included an .env.example file containing all the necessary keys for Neon, Polar, Better-Auth, and Cloudflare R2.
Initial Setup Checklist
- Get your DATABASE_URL from your Neon Tech project dashboard.
- Generate a unique BETTER_AUTH_SECRET by running
npx @better-auth/cli secret. - Fill in your POLAR_ACCESS_TOKEN from your Polar.sh settings to enable billing.
3. Database Setup (Drizzle)
I use Drizzle ORM for its speed and type safety. To get your database ready, you need to sync the schema. I recommend the "push" method for rapid development.
Managing Your Data
Run pnpm drizzle-kit studio at any time to open a local GUI and browse or edit your database rows directly.
4. Start the Application
Everything is set. You can now boot the Next.js 16 development server.
Local URL
Access your app at http://localhost:3000.
Auth Portal
Navigate to /auth to register your first user.
5. Gaining Admin Rights
I have included a dedicated Admin Dashboard to manage users and view analytics. Because this is your first run, you need to elevate your account role manually.
Create a new account via the /auth page in your browser.
In your terminal, run pnpm drizzle-kit studio.
Locate your record in the user table and change your role from user to admin.
Once saved, refresh the app. The Admin Dashboard will be accessible in your sidebar.
Deep Dives
Now that you are up and running, I recommend exploring these sections to fully master your SaaS.