GUIDE

How do you self-host Supabase?

Self-hosted Supabase is the open-source Supabase stack (Postgres, GoTrue auth, PostgREST, Realtime, Storage, Edge Functions, and Studio) running on your own servers, usually with Docker Compose, instead of on Supabase's managed platform. Powabase's Apache-2.0 self-host edition runs that same data plane unchanged and adds a RAG pipeline and agent runtime on top.

Last reviewed: September 24, 2026

How do you self-host Supabase?

Supabase's official path is Docker Compose. You clone the supabase/supabase repository, copy its docker/ directory into a project folder, copy .env.example to .env, pull the images, and start the stack. On Linux, Supabase also publishes a setup script that does this for you, and a run.sh helper wraps start, stop, restart, and printing credentials. The stack runs Postgres, Studio, Auth (GoTrue), PostgREST, Realtime, Storage with imgproxy, Edge Runtime for functions, and postgres-meta, all behind an API gateway (Envoy in current releases). Supabase lists a minimum of 4 GB of RAM, 2 CPU cores, and 40 GB of SSD storage. You can drop services you don't need, such as Realtime or Edge Functions, from docker-compose.yml to save resources. Updates come from an update.sh script that merges the latest self-hosted/v* configuration over your files. Don't confuse this with the Supabase CLI's local development stack, which Supabase says is not hardened for production.

What do you need to configure before going live?

The defaults in .env.example exist to get the stack running, and Supabase is explicit that you should never start a real deployment with them. Before anything touches the internet, replace every secret and put the gateway behind TLS. Then set up email: GoTrue needs an SMTP server to send confirmation, magic-link, and password-reset emails, configured through the SMTP_* variables (Supabase suggests a provider such as AWS SES). Decide where Storage keeps files, local disk or an S3-compatible bucket, and plan for how big the Postgres volume will grow. Finally, keep the Postgres port off the public network and reach it through the gateway or a private connection.

  • JWT secret and the API keys signed with it
  • Postgres password
  • Studio dashboard username and password
  • SMTP settings for auth emails
  • TLS termination in front of the API gateway
  • Storage backend and Postgres volume sizing

What do you give up when self-hosting Supabase?

Supabase's own docs list what the managed platform has and self-hosted Supabase doesn't: branching, advanced metrics beyond logs, managed backups and point-in-time recovery, analytics and vector buckets, ETL, and the platform management API. Self-hosted Studio also runs a single project and has no organizations. So if you want three environments, you run three stacks. The work moves to you as well. Backups are your own pg_dump or WAL archiving, upgrades are your job to test and roll out, and monitoring, log retention, and alerting are yours to wire up. None of this is unusual for running Postgres in production, but budget for it. In return you get full control of where data lives, no per-project platform fees, and a stack you can run inside a private network. Supabase recommends self-hosting when you need that control, have compliance rules that rule out managed services, or need an isolated environment.

Self-hosted Supabase for AI apps

Self-hosted Supabase gives you pgvector, so you can store embeddings and run similarity, keyword, and hybrid search in SQL. Everything around those queries is left to you. You need a parser for PDFs, Office files, and scanned images, a chunking strategy, a job that calls an embedding model when documents change, a reranker, and some way to run an agent that calls tools and remembers sessions. Supabase documents an automatic-embeddings pattern built from Edge Functions, pgmq, pg_net, and pg_cron, which works but is yours to maintain. Agent frameworks such as LangChain run in a separate service with their own state. On a self-hosted stack every one of those pieces is another container to deploy, secure, and upgrade. If your app is mostly CRUD with a little semantic search, plain Supabase is enough. If documents and agents are the core of the product, a stack that already has the AI layer will save you most of that work.

How do you self-host Powabase?

The Powabase self-host edition is a single-project stack under Apache-2.0. Its data plane is the upstream Supabase self-hosted stack running the official images unchanged: GoTrue, PostgREST, Storage with imgproxy, Realtime, postgres-meta, and Postgres 15 with pgvector. On top of that it adds the Powabase AI service and a background worker for sources, knowledge bases, agents, and workflows, with Redis as the job queue and a Studio fork that shows the AI features, for 12 services behind a Kong gateway. Setup is four commands: copy .env.example, run gen-keys.py to generate your secrets, set your OPENAI_API_KEY (embeddings need a key, and you can add Anthropic and other providers), and run docker compose up -d. Image versions are pinned, and updating is a git pull, docker compose pull, and docker compose up -d. Because the base is Supabase, your existing SQL, RLS policies, and supabase-js code carry over. For a platform-level comparison, see Powabase vs Supabase.

How Powabase does it

How Powabase does it

Powabase gives you the Supabase backend you already know with the AI layer built in, on your own servers or ours. The self-host edition is one docker compose up under Apache-2.0. Powabase Cloud gives every project its own Postgres instance in an isolated environment, and Enterprise adds a supported Kubernetes Helm chart and private hosting.

  • Same data plane as self-hosted Supabase: GoTrue, PostgREST, Storage, Realtime, and Postgres with pgvector
  • A RAG pipeline that extracts, chunks, embeds, and indexes PDFs, Office files, and images (with OCR) on upload
  • Vector, full-text (BM25), hybrid, and tree search, with optional reranking
  • An agent runtime with built-in tools, your own HTTP tools, MCP servers, sessions stored in Postgres, and human approval
  • Workflows with webhook, cron, and interval triggers
  • Bring your own LLM keys, so model costs and data handling stay with you

Self-hosted Supabase vs self-hosted Powabase

  • License

    Self-hosted Supabase:
    Apache-2.0
    Self-hosted Powabase:
    Apache-2.0
  • Start command

    Self-hosted Supabase:
    docker compose up (via run.sh or the setup script)
    Self-hosted Powabase:
    docker compose up -d
  • Postgres, auth, REST, storage, realtime

    Self-hosted Supabase:
    Yes
    Self-hosted Powabase:
    Yes, the same upstream Supabase images
  • pgvector

    Self-hosted Supabase:
    Yes
    Self-hosted Powabase:
    Yes
  • Document extraction, chunking, embedding

    Self-hosted Supabase:
    Build your own
    Self-hosted Powabase:
    Built in, on upload
  • Hybrid search and reranking

    Self-hosted Supabase:
    Hybrid search in SQL; reranking is yours to add
    Self-hosted Powabase:
    Built in
  • Agent runtime and workflows

    Self-hosted Supabase:
    Not included
    Self-hosted Powabase:
    Built in
  • Projects per stack

    Self-hosted Supabase:
    One
    Self-hosted Powabase:
    One
  • Managed backups and PITR

    Self-hosted Supabase:
    Not included; run your own
    Self-hosted Powabase:
    Not included; run your own

FAQ

Questions.

Yes. Supabase is open source under Apache-2.0, and the official way to self-host it is Docker Compose using the docker directory in the supabase/supabase repository. Supabase lists a minimum of 4 GB RAM, 2 CPU cores, and 40 GB of SSD storage.

The software is free under Apache-2.0. You pay for the servers, storage, and bandwidth, plus the time to run backups, upgrades, and monitoring yourself. Self-hosted Powabase is free on the same terms, and you bring your own LLM keys.

Per Supabase's docs: branching, advanced metrics beyond logs, managed backups and point-in-time recovery, analytics and vector buckets, ETL, and the platform management API. Self-hosted Studio also supports only one project, with no organizations.

No. A self-hosted Supabase stack is a single project, and Studio doesn't support multiple organizations or projects. To run several projects, you run several stacks. Self-hosted Powabase works the same way; multi-project hosting is part of Powabase Cloud and Enterprise.

Yes. pgvector is available in self-hosted Supabase for similarity, keyword, and hybrid search in SQL. Extraction, chunking, embedding jobs, and reranking are yours to build. Self-hosted Powabase ships that pipeline on the same Postgres.

Yes. Powabase's self-host edition runs the same upstream Supabase services unchanged, so your SQL, RLS policies, and client code carry over, and adds document extraction, knowledge bases with hybrid search, agents, and workflows. It is Apache-2.0 and starts with one docker compose up.

Supabase ships an update.sh script that merges the latest self-hosted configuration into your files. Powabase pins image versions in docker-compose.yml, so you update with git pull, docker compose pull, and docker compose up -d. Back up Postgres before either.

Docs

Sources

  1. https://supabase.com/docs/guides/self-hosting: Features unavailable when self-hosting (branching, advanced metrics, managed backups and PITR, analytics and vector buckets, ETL, management API); single-project Studio; who self-hosting suits.
  2. https://supabase.com/docs/guides/self-hosting/docker: Docker Compose setup, services, required secrets, SMTP settings, minimum hardware, update.sh, removing optional services.
  3. https://supabase.com/docs/guides/ai/automatic-embeddings: Automatic embeddings as a documented pattern using Edge Functions, pgmq, pg_net, and pg_cron.
  4. https://supabase.com/docs/guides/ai: pgvector toolkit with semantic, keyword, and hybrid search.
  5. https://github.com/supabase/supabase: Supabase is open source under Apache-2.0.
  6. https://github.com/powabase-ai/powabase: Powabase self-host edition: Apache-2.0, 12 services, upstream Supabase images unchanged, Quickstart commands, OpenAI key requirement, pinned image updates.