2025-12-21 13:36:04 +01:00
---
title: Supabase Cloud Setup
description: Guide to setting up Supabase cloud for ClassroomIO.
---
2025-05-20 18:56:22 +01:00
2025-12-21 13:36:04 +01:00
import { Step, Steps } from 'fumadocs-ui/components/steps';
import { Callout } from 'fumadocs-ui/components/callout';
2024-02-07 08:15:36 +00:00
In this guide, you will learn how to setup a supabase cloud project and link it to your local environment.
## Who is this guide for?
1. You don't want to setup supabase on your local machine
2. You can't run docker on your computer
3. You are experiencing performance issues using supabase locally
2025-12-21 13:36:04 +01:00
4. You want to selfhost our frontend app but use supabase cloud
2024-02-07 08:15:36 +00:00
If your requirement matches any of the above, then this guide is for you.
## Video Walkthrough
2025-12-21 13:36:04 +01:00
<div style={{ display: 'flex', justifyContent: 'center', marginY: '16px' }}>
2024-02-07 08:15:36 +00:00
<iframe
width="560"
height="315"
src="https://www.youtube.com/embed/dAZAZ0oiky0?si=1h-KtppNqJ3U4BTe"
title="YouTube video player"
2025-12-21 13:36:04 +01:00
frameBorder="0"
2024-02-07 08:15:36 +00:00
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
2025-12-21 13:36:04 +01:00
allowFullScreen
style={{ borderRadius: '8px' }}
2024-02-07 08:15:36 +00:00
></iframe>
</div>
2025-12-21 13:36:04 +01:00
## Step by Step Guide
2024-02-07 08:15:36 +00:00
<Steps>
2025-12-21 13:36:04 +01:00
<Step>
2024-02-07 08:15:36 +00:00
### Create a Supabase project
For this step you need to have signed up for supabase and create an account, just visit [supabase.com](https://supabase.com).
Once you have an account just click on the _New Project_ on your dashboard. After that you should see a similar screen to the below, fill in the fields.
2025-12-21 13:36:04 +01:00

2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00
<Callout title="Important">
2024-02-07 08:15:36 +00:00
Make sure you save your database password somewhere, else you won't be able to get it back
anywhere in the dashboard for security reasons.
</Callout>
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2025-10-04 06:56:14 +01:00
### Setup Supabase CLI
Follow the instructions [here](https://supabase.com/docs/guides/local-development/cli/getting-started) to setup the Supabase CLI on your computer.
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2024-02-07 08:15:36 +00:00
### Login to Supabase via the CLI
Open your terminal and go to the root of the project. Run the following:
2025-12-21 13:36:04 +01:00
```zsh title="Terminal"
2025-10-04 06:56:14 +01:00
supabase login
2024-02-07 08:15:36 +00:00
```
Follow the instruction in your terminal to generate your access token. Paste the token in the console and hit **Enter**
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2024-02-07 08:15:36 +00:00
### Push migrations to your Supabase project
- Go to the supabase dashboard, go to your project, click on the settings icon on the left side bar
2025-12-21 13:36:04 +01:00

2024-02-07 08:15:36 +00:00
- Copy the URL in the image above for your `db url`
- Paste it somewhere
- In the url, replace `[YOUR PASSWORD]` with your db password (which you saved in section 1).
- Then run in your terminal:
2025-12-21 13:36:04 +01:00
```zsh title="Terminal"
2025-10-04 06:56:14 +01:00
supabase db push --db-url "URL HERE"
2024-02-07 08:15:36 +00:00
```
2025-12-21 13:36:04 +01:00
<Callout title="Important">
2024-02-07 08:15:36 +00:00
Make sure you preserve the double quotes before and after the url. Only replace `URL HERE` with
your `db url` that contains your password
</Callout>
#### Result
2025-12-21 13:36:04 +01:00

2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2024-02-07 08:15:36 +00:00
### Configure Auth in your Supabase project
2024-09-30 01:20:19 +01:00
Here we will update our email configurations, to prevent supabase from sending confirmation emails on signup. This is because we don't use Supabase for email verification, we handle that internally due to the quality of the email.
2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00

2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2024-09-30 01:20:19 +01:00
### Configure SMTP
2025-12-21 13:36:04 +01:00
Supabase [now requires adding custom SMTP](https://github.com/orgs/supabase/discussions/29370) to your supabase project in order to avoid abuse of their system. Without adding a custom SMTP, your signup requests to your supabase project will fail. To avoid this, you should go to the [SMTP section](https://supabase.com/dashboard/project/_/settings/auth) of your supabase settings.
2024-09-30 01:20:19 +01:00
Make sure to toggle **Enable Custom SMTP** and fill in the following fields:
- Sender email
- Sender name
- SMTP host
- SMTP port
- SMTP username
- SMTP password
2025-12-21 13:36:04 +01:00

2024-09-30 01:20:19 +01:00
2025-12-21 13:36:04 +01:00
<Callout title="ℹ ️ Learn More">
2024-09-30 01:20:19 +01:00
Learn more about setting up SMTP [here](https://supabase.com/docs/guides/auth/auth-smtp)
</Callout>
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2024-02-07 08:15:36 +00:00
### Add configurations to your environment variables
Now with all these set up you need to get update the .env file in `apps/dashboard`. You need to update the following environment variables:
2025-12-21 13:36:04 +01:00
```zsh title="env"
2024-02-07 08:15:36 +00:00
PUBLIC_SUPABASE_URL=
PUBLIC_SUPABASE_ANON_KEY=
2024-03-22 09:43:56 +01:00
PRIVATE_SUPABASE_SERVICE_ROLE=
2024-02-07 08:15:36 +00:00
```
2025-12-21 13:36:04 +01:00
To get the correct environment variables, follow the instructions in this image:
2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00

2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00
</Step>
<Step>
2024-02-07 08:15:36 +00:00
### Tada - That's all
Now you can run:
2025-12-21 13:36:04 +01:00
```zsh title="Terminal"
2024-02-07 08:15:36 +00:00
pnpm dev --filter=dashboard
```
- Open the url in your browser
- Click on Sign up
2025-12-21 13:36:04 +01:00
- And that's it...
2024-02-07 08:15:36 +00:00
2025-12-21 13:36:04 +01:00
<Callout title="ℹ ️ Learn More">
Visit the [Sign up guide](/docs/quickstart/signup) to learn how to signup
2024-02-07 08:15:36 +00:00
</Callout>
2025-12-21 13:36:04 +01:00
</Step>
2024-02-07 08:15:36 +00:00
</Steps>