Deployment

Checklist

Let's deploy your TurboStarter app to production!

When you're ready to deploy your project to production, follow this checklist.

This process may take a few hours and some trial and error, so buckle up — you're almost there!

Create database instance

Why it's necessary?

A production-ready database instance is essential for storing your application's data securely and reliably in the cloud. PostgreSQL is the recommended database for TurboStarter due to its robustness, features, and wide support.

How to do it?

You have several options for hosting your PostgreSQL database:

  • Supabase - Provides a fully managed Postgres database with additional features
  • Vercel Postgres - Serverless SQL database optimized for Vercel deployments
  • Neon - Serverless Postgres with automatic scaling
  • Turso - Edge database built on libSQL with global replication
  • DigitalOcean - Managed database clusters with automated failover

Choose a provider based on your needs for:

  • Pricing and budget
  • Geographic region availability
  • Scaling requirements
  • Additional features (backups, monitoring, etc.)

Migrate database

Why it's necessary?

Pushing database migrations ensures that your database schema in the remote database instance is configured to match TurboStarter's requirements. This step is crucial for the application to function correctly.

How to do it?

You basically have two possibilities of doing a migration:

TurboStarter comes with predefined Github Actions workflow to handle database migrations. You can find its definition in the .github/workflows/publish-db.yml file.

What you need to do is to set your DATABASE_URL as a secret for your Github repository.

Then, you can run the workflow which will publish the database schema to your remote database instance.

Check how to run Github Actions workflow.

Configure OAuth Providers

Why it's necessary?

Configuring OAuth providers like Google or Github ensures that users can log in using their existing accounts, enhancing user convenience and security. This step involves setting up the OAuth credentials in the provider's developer console, configuring the necessary environment variables, and setting up callback URLs to point to your production app.

How to do it?

  1. Follow the provider-specific guides to set up OAuth credentials for the providers you want to use. For example:
  2. Once you have the credentials, set the corresponding environment variables in your project. For the example providers above:
    • For Google: GOOGLE_CLIENT_ID and GOOGLE_CLIENT_SECRET
    • For Github: GITHUB_CLIENT_ID and GITHUB_CLIENT_SECRET
  3. Ensure that the callback URLs for each provider are set to point to your production app. This is crucial for the OAuth flow to work correctly.

You can add or remove OAuth providers based on your needs. Just make sure to follow the provider's setup guide, set the required environment variables, and configure the callback URLs correctly.

Setup billing provider

Why it's necessary?

Well - you want to get paid, right? Setting up billing ensures that you can charge your users for using your SaaS application, enabling you to monetize your service and cover operational costs.

How to do it?

  • Create a Stripe or Lemon Squeezy account.
  • Update the environment variables with the correct values for your billing service.
  • Point webhooks from Stripe or Lemon Squeezy to /api/billing/webhook.
  • Refer to the relevant documentation for more details on setting up billing.

Setup emails provider

Why it's necessary?

Setting up an email provider is crucial for your SaaS application to send notifications, confirmations, and other important messages to your users. This enhances user experience and engagement, and is a standard practice in modern web applications.

How to do it?

  • Create an account with an email service provider of your choice. See available providers for more information.
  • Update the environment variables with the correct values for your email service.
  • Refer to the relevant documentation for more details on setting up email.

Environment variables

Why it's necessary?

Setting the correct environment variables is essential for the application to function correctly. These variables include API keys, database URLs, and other configuration details required for your app to connect to various services.

How to do it?

Use our .env.example files to get the correct environment variables for your project. Then add them to your hosting provider's environment variables. Redeploy the app once you have the URL to set in the environment variables.

Deploy web app to production

Why it's necessary?

Because your users are waiting! Deploying your Next.js app to a hosting provider makes it accessible to users worldwide, allowing them to interact with your application.

How to do it?

Deploy your Next.js app to Vercel or any other hosting provider. Copy the deployment URL and set it as an environment variable in your project's settings.

That's it! Your app is now live and accessible to your users, good job! 🎉

Other things to consider

  • Update the legal pages with your company's information (privacy policy, terms of service, etc.).
  • Remove the placeholder blog and documentation content / or replace it with your own.
  • Customize authentication emails and other email templates.
  • Update the favicon and logo with your own branding.
  • Update the FAQ and other static content with your own information.

Last updated on

On this page

Ship your startup everywhere. In minutes.