Skip to main content
The Supabase CLI is available for macOS, Windows, and Linux. Choose your installation method based on your operating system and preferences.

Prerequisites

Before installing the Supabase CLI, ensure you have:
  • Docker Desktop (or compatible container runtime) - Required for running Supabase locally
  • Node.js 20+ (if using npm/npx method)
While the CLI can be installed via npm, it requires Node.js 20 or later. Older versions like Node.js 16 are not supported.

Installation Methods

The easiest way to install the CLI on macOS is using Homebrew:
brew install supabase/tap/supabase

Verify Installation

After installation, verify the CLI is working:
supabase --version

Updating

To update to the latest version:
brew upgrade supabase

Installing Docker

The Supabase CLI uses Docker containers to run the local development stack. Install Docker Desktop for your platform:

Docker Desktop for macOS

  1. Download Docker Desktop for Mac
  2. Install and start Docker Desktop
  3. Configure Docker settings:
Docker settings on Mac
Recommended Settings:
  • ✅ Use integrated virtualization framework
  • ✅ Enable VirtioFS
  • ✅ Use osxfs (legacy) file sharing

Alternative Container Runtimes

You can also use:

Post-Installation

Verify Docker Installation

Verify Docker is running:
docker --version
docker ps

Verify Supabase CLI Installation

Check that the CLI is properly installed:
supabase --version
You should see output like:
supabase 1.x.x

First-Time Setup

The first time you run supabase start, the CLI will download all necessary Docker images. This may take several minutes:
supabase init
supabase start
The initial download includes images for PostgreSQL, PostgREST, GoTrue, Kong, Realtime, Storage, and other services - approximately 2-3 GB total.

Updating the CLI

When to Update

Check for new releases on the Supabase CLI releases page. We recommend updating regularly to get the latest features and bug fixes.

Update Process

Update the CLI using the same method you used to install it:
brew upgrade supabase

Important: Stop Containers Before Upgrading

Before upgrading, stop your local Supabase containers and delete data volumes to ensure services can apply new migrations cleanly.
Backup and stop running containers:
# Save your schema changes
supabase db diff -f my_schema

# Save your data
supabase db dump --local --data-only > supabase/seed.sql

# Stop and remove containers (--no-backup deletes volumes)
supabase stop --no-backup
After upgrading, restart:
supabase start

Troubleshooting

macOS/Linux:
  • Ensure Homebrew’s bin directory is in your PATH
  • Restart your terminal
  • Try running with full path: /opt/homebrew/bin/supabase
Windows:
  • Ensure Scoop’s shims directory is in your PATH
  • Restart PowerShell/Command Prompt
Error: Cannot connect to the Docker daemonSolution:
  • Start Docker Desktop
  • Verify Docker is running: docker ps
  • On Linux, ensure your user is in the docker group: sudo usermod -aG docker $USER
Error when using npx: The Supabase CLI requires Node.js 20 or laterSolution:
  • Update Node.js to version 20 or later
  • Use a different installation method (Homebrew, Scoop)
  • Use a Node version manager like nvm
Error: Port 54321 is already in useSolution:
  • Stop any services using ports 54321-54324
  • Or configure custom ports in supabase/config.toml

Next Steps

Local Development

Set up your local development environment

CLI Reference

Explore all CLI commands

Migrations

Learn database migration workflows

GitHub Actions

Set up CI/CD with GitHub Actions