Self Hosting

Supabase is a Hosted Platform, so you don't have to deploy it yourself. However, if you want to configure and deploy it yourself, this is also possible.

Before you begin

If you are about to step through this Guide, please record your steps! You can help us improve by adding missing details and fixing errors.

The self-hosted version of Supabase does not include a UI yet. We are working on this in stages, starting with our UI library (more context).

In the meantime, here are some suggested tools for interacting with your Postgres Database:

Get the Docker Compose

We provide a Docker Compose directory which is includes all of the tools required for building on top of Supabase.

You can download the Docker files in various ways:

Option 1: Using our CLI

Make sure the CLI is installed:

npm install -g supabase

Then run in any folder to create a docker folder with a docker-compose.yml:

supabase eject

Option 2: Clone our repo

# 1. Copy an empty repo
git clone
# 2. Move into the empty repo
cd supabase/docker

Option 3: Using a shallow clone

If you use Git version >2.25, you can use a shallow clone to download this folder to your local machine:

# 1. Copy an empty repo
git clone --no-checkout
# 2. Move into the empty repo
cd supabase
# 3. Initialize sparse-checkout
git sparse-checkout init --cone
# 4. Checkout the folder
git sparse-checkout set docker

Running Supabase

Now that you have the Docker set up on your local machine, you can start it here by running

docker-compose up


Make sure you update the default passwords and secrets before running in Production. After you have regenerated the JWT secret, you will need to encode a new anon and service_role API key and update them here. For example, using

The data you will need to encode includes:

# anon Payload:
"iss": "supabase",
"iat": 1603968834,
"exp": 2550653634,
"aud": "",
"sub": "",
"role": "anon"
# service_role Payload:
"iss": "supabase",
"iat": 1603968834,
"exp": 2550653634,
"aud": "",
"sub": "",
"role": "service_role"

Configuring each service

Supabase is made up of several services. We have prefilled the docker-compose file with all the configuration you need to get started. If you would like to change any of the configuration, you can update the env variables in the docker-compose file.

Here are a list of environment variables for each service:

Configuring email

GoTrue requires an SMTP server to send emails for all authentication actions. You will need to provide the following settings inside the .env file here.

API Keys

All config for the API Gateway is stored in the kong directory. Inside kong.yml you'll find the routing for all services, the routing rules, and down the bottom you'll find the JWTs capable of accessing services that require API Key access.

See the full docs here.


See the following guides to deploy Docker Compose setup using your preferred tool and platform:

One-click deploys

For some individual tools, we also provide images and deployments into cloud marketplaces:



Next steps