logo
SaaSkit

Getting Started

Get your project running in minutes

Prerequisites

Before you can get started, you will need to have the following installed on your machine.

  1. Node.js (v20 or higher) (with npm)
  2. Git
  3. VSCode (or any other code editor)

Project Setup

Clone the repository

git clone https://github.com/SaaSkitHQ/SaaSkit-Allin.git
cd SaaSkit-Allin

Remove the .git folder

rm -rf .git

Install the dependencies

git checkout stripe // or creem.io, polar.sh, dodopayments
npm install

Create a .env file in the root directory and fill in the following:

# Website
NEXT_PUBLIC_BASE_URL="http://localhost:3000" // use real domain in production
 
# Authentication (Betterauth)
BETTER_AUTH_URL="http://localhost:3000" // use real domain in production
BETTER_AUTH_SECRET=
 
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
 
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
 
DISCORD_CLIENT_ID=
DISCORD_CLIENT_SECRET=
 
# Database (Neon or Supabase)
DATABASE_URL=
 
# Email (Resend)
RESEND_API_KEY=
EMAIL_SENDER_NAME=
EMAIL_SENDER_ADDRESS=
 
# Storage (Cloudflare R2)
STORAGE_REGION="auto"
STORAGE_ACCESS_KEY_ID=
STORAGE_SECRET_ACCESS_KEY=
STORAGE_BUCKET_NAME=
STORAGE_ENDPOINT=
NEXT_PUBLIC_STATIC_DOMAIN=
 
# Payment (Stripe / Polar / Creem / Dodopayments)
STRIPE_SECRET_KEY=
STRIPE_WEBHOOK_SECRET=
 
POLAR_ACCESS_TOKEN=
POLAR_WEBHOOK_SECRET=
 
DODO_PAYMENTS_API_KEY=
DODO_PAYMENTS_WEBHOOK_SECRET=
 
CREEM_API_KEY=
CREEM_WEBHOOK_SECRET=
 
# Rate Limit (Upstash)
UPSTASH_REDIS_REST_URL=
UPSTASH_REDIS_REST_TOKEN=
 
# Logging (Betterstack)
NEXT_PUBLIC_BETTER_STACK_SOURCE_TOKEN=
NEXT_PUBLIC_BETTER_STACK_INGESTING_URL=
 
# Analytics (Posthog)
NEXT_PUBLIC_POSTHOG_KEY=
NEXT_PUBLIC_POSTHOG_HOST=
NEXT_PUBLIC_COOKIELESS_MODE="false" // or true

Note that the app would not be completely functional until you add the values for all of the env variables.

Setup the database

You need to migrate the db schema to your database provider. Know how →

Run the project

npm run dev

On this page