Quick Setup Guide
Get your SaaS project up and running in minutes with these simple steps.
Clone and Install
Get started by cloning the repository and installing dependencies:
git clone {url} my-saas-appcd my-saas-apppnpm install
Environment Setup
Create a .env
file in the root directory with the following variables:
# Supabase ConfigurationNEXT_PUBLIC_SUPABASE_URL=your-project-urlNEXT_PUBLIC_SUPABASE_ANON_KEY=your-anon-keySUPABASE_SERVICE_ROLE_KEY=your-service-role-key# Stripe ConfigurationNEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=your-publishable-keySTRIPE_SECRET_KEY=your-secret-keySTRIPE_WEBHOOK_SECRET=your-webhook-secret# App ConfigurationNEXT_PUBLIC_APP_URL=http://localhost:3000NEXT_PUBLIC_COMPANY_NAME="Your Company"NEXT_PUBLIC_CONTACT_EMAIL=support@example.com# Optional: Analytics & MonitoringNEXT_PUBLIC_POSTHOG_KEY=your-posthog-keyNEXT_PUBLIC_POSTHOG_HOST=your-posthog-hostNEXT_PUBLIC_SENTRY_DSN=your-sentry-dsn
Database Setup
Your Supabase project comes with a pre-configured schema in the supabase/seed.sql
file. This includes:
- Core tables (users, customers, products, prices)
- Row Level Security (RLS) policies
- Default products and pricing tiers
To set up your database, run the SQL commands from the seed.sql
file in your Supabase SQL Editor:
- Open your Supabase project dashboard
- Navigate to the SQL Editor
- Copy the contents of
supabase/seed.sql
- Paste and execute the SQL commands
Start Development
Run the development server:
pnpm dev
Your app should now be running at http://localhost:3000