Skip to main content
Next.js

Installation

Once you’ve downloaded your Next.js project, get started by installing all of the dependencies. You can do this by running the install command using your package manager of choice:
npm install

Environment variables

Depending on which technologies you selected for your boilerplate, you’ll need to fill in the .env file with the necessary environment variables.

Site

This is the full URL of your site. By default, ShipKit will use port :3000.
# .env
NEXT_PUBLIC_SITE_URL=http://localhost:3000

Database

Add your database URL to the .env file.
# .env
DATABASE_URL=
DATABASE_AUTH_TOKEN= # <-- Only for Turso

Stripe

Sign up for a Stripe account. Add your Stripe secret key and webhook secret to the .env file.
# .env
STRIPE_SECRET_KEY=
STRIPE_WEBHOOK_SECRET=

Resend

Sign up for a Resend account. Add your API key and audience ID to the .env file.
# .env
RESEND_API_KEY=
RESEND_AUDIENCE_ID=

Lucia - Google OAuth

To use Lucia, you’ll need to add your Google OAuth client ID, client secret, and redirect URI to the .env file.
# .env
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
GOOGLE_CLIENT_REDIRECT_URI=

Clerk

Sign up for a Clerk account and create a new project.Add your public Clerk publishable key, sign-in URL, sign-up URL, and secret key to the .env file.
# .env
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=
NEXT_PUBLIC_CLERK_SIGN_IN_URL=
NEXT_PUBLIC_CLERK_SIGN_UP_URL=
CLERK_SECRET_KEY=

Supabase

Sign up for a Supabase account and create a new project.Add your public Supabase URL, public Supabase anon key, and Supabase service role key to the .env file.
# .env
NEXT_PUBLIC_SUPABASE_URL=
NEXT_PUBLIC_SUPABASE_ANON_KEY=
SUPABASE_SERVICE_ROLE_KEY=

Local development

Once you’ve installed all of the dependencies and filled in the .env file, you can start the development server using the following command:
npm run dev
Visit: http://localhost:3000