Skip to content
EliaTolinPublic

About

CLI to switch between multiple Supabase accounts: save each account once, then switch the Supabase CLI with one command. Tokens stay in the OS keychain. macOS, Linux, Windows.

Topics

Resources

Stars

32 stars

Watchers

0 watching

Forks

Repository files navigation

supawho demo

supawho

Switch between multiple Supabase accounts in seconds β€” on any OS.

Your access tokens live in your operating system's native secret vault: supawho never writes them to a file.
One command to jump between projects and clients. πŸ”

Documentation β†’ supawho.dev


Release Docs License: MIT

macOS Linux Windows


Juggling multiple Supabase accounts?

Tired of the endless supabase logout β†’ supabase login β†’ paste token dance every time you switch project or client?

supawho saves each account once and lets you jump between them in seconds, with your tokens kept in the OS secret vault instead of a file.


✨ Why supawho

πŸ” Secure by design Tokens live in the OS secret store β€” encrypted, never written to a file
πŸ”Ž Know who is who supawho whoami maps every account to its real email + organizations
🩺 Health check supawho doctor flags revoked tokens and environment issues, with the fix for each
πŸ–₯️ Truly cross-platform One static binary for macOS, Linux and Windows. No runtime to install
⚑ Instant switching supawho use client-a and you're logged in
πŸ”„ Self-updating supawho upgrade keeps you current on any OS
🍺 Installs everywhere Homebrew, .deb/.rpm/.apk packages, or a one-line script

⚑ Quick start

# 1. Install (macOS shown β€” Linux & Windows below)
brew install EliaTolin/tap/supawho

# 2. Use it
supawho add          # save an account (once): asks for a name and the token, input hidden
supawho use work     # switch to it in a second
supawho whoami       # forgot which is which? map them all

Not on macOS? Grab your one-liner from Installation β€” install.sh for Linux, install.ps1 for Windows.

Full walkthrough: Get started with supawho.


πŸ“¦ Installation

Pick your platform β€” every option gives you the same single, dependency-free binary.

🍎 macOS

brew install EliaTolin/tap/supawho
Prefer a script or a raw binary?
curl -fsSL https://raw.githubusercontent.com/EliaTolin/supawho/main/install.sh | bash

Or grab the Darwin archive from the releases page and drop the binary in your PATH.

🐧 Linux

curl -fsSL https://raw.githubusercontent.com/EliaTolin/supawho/main/install.sh | bash
Native packages (.deb / .rpm / .apk)

Download the package for your distro and CPU (x86_64 or arm64) from the releases page, then:

# Debian / Ubuntu
sudo dpkg -i supawho_*_linux_amd64.deb

# Fedora / RHEL
sudo rpm -i supawho_*_linux_amd64.rpm

# Alpine
sudo apk add --allow-untrusted supawho_*_linux_amd64.apk

ℹ️ Linux needs a Secret Service provider (GNOME Keyring, KWallet, …) running to store tokens.

πŸͺŸ Windows

irm https://raw.githubusercontent.com/EliaTolin/supawho/main/install.ps1 | iex
Prefer the raw binary?

Download the Windows .zip for your CPU (x86_64 or arm64) from the releases page, extract supawho.exe, and add it to your PATH.

πŸ› οΈ From source

Requires Go 1.25+:

git clone https://github.com/EliaTolin/supawho.git
cd supawho
go install .

πŸ”‘ Get your Supabase access token

  1. Open supabase.com/dashboard β†’ profile icon (top right)
  2. Account preferences β†’ Access Tokens
  3. Generate new token, name it, and copy it

πŸ’‘ The token starts with sbp_ and is shown only once β€” copy it right away.

Then save it. supawho add asks for a name and the token, and hides the token as you paste it, so it stays out of your shell history:

supawho add

For scripts there is a one-line form, supawho add <name> "$SUPABASE_TOKEN". Avoid typing a literal token on the command line: it ends up in your shell history.


πŸš€ Usage

Command Description
supawho Interactive account picker
supawho add Save a new account (guided, hidden token input)
supawho add <name> <token> Save a new account in one line, for scripts
supawho use <name> Switch to an account
supawho list Show all saved accounts
supawho whoami [name] Reveal the email + organizations behind each account
supawho find <project-ref> Find which account owns a project
supawho projects [name] List the projects of each account (--json for scripts)
supawho doctor [name] Check token validity and system health (--json for scripts)
supawho rename <old> <new> Rename a saved account
supawho remove <name> Delete an account
supawho upgrade Update to the latest version
supawho version Print the installed version

Every command has its own page in the command reference.

Interactive mode

Just run supawho with no arguments:

   ___  _   _ ___  ___  _    _ _  _  ___
  / __|| | | | _ \/ _ \| |  | | || |/ _ \
  \__ \| |_| |  _/ (_) | |/\| | __ | (_)
  |___/ \___/|_|  \__\_\__/\__|_||_|\___/

     πŸ” Who are you today?

Select an account:

  1) myproject
  2) another-project

Enter number (1-2):

Which account is which?

Got a dozen accounts and can't remember whose is whose? supawho whoami asks Supabase and maps each one to its email and organizations β€” a revoked token is flagged on its own row without breaking the rest:

supawho whoami output

Add a name to look up a single account: supawho whoami client-a.

Which account owns this project?

The reverse lookup: paste a Supabase project ref and supawho find tells you which saved account it lives in.

$ supawho find abcdefghijklmnopqrst

  βœ“ Found in account 'client-a'

  Project       storefront
  Reference     abcdefghijklmnopqrst
  Organization  Client A
  Region        eu-central-1
  Status        ACTIVE_HEALTHY
  Email         you@example.com
  Account       client-a

  Switch to it:  supawho use client-a

What's in each account?

supawho projects lists every project an account can reach, with its reference, organization, region and status. Add a name to list a single account, or --json for scripts.

$ supawho projects client-a

  client-a (2)
  PROJECT    REFERENCE             ORGANIZATION  REGION        STATUS
  api        abcdefghijklmnopqrst  Client A      eu-central-1  ACTIVE_HEALTHY
  api-dev    tsrqponmlkjihgfedcba  Client A      eu-central-1  INACTIVE

πŸ”„ Keeping supawho up to date

supawho tells you when a new version ships, and updates itself with one command:

supawho upgrade

It downloads the latest release, verifies its checksum, and swaps the binary in place. If supawho was installed through a package manager, it won't fight it β€” it points you to the right command instead:

Installed via How it updates
Homebrew brew upgrade supawho
Install script / raw binary supawho upgrade
.deb / .rpm / .apk your system package manager

Prefer silence? Set SUPAWHO_NO_UPDATE_CHECK=1 to disable the background version check.


πŸ”’ Why is it secure?

supawho never writes your tokens to a file. They live in your operating system's native secret store β€” the same encrypted vault the OS uses for passwords and certificates:

  • macOS β†’ Keychain
  • Linux β†’ Secret Service (GNOME Keyring / KWallet, via libsecret)
  • Windows β†’ Credential Manager
supawho Plain-text files
Encrypted at rest βœ… ❌
Protected by system login βœ… ❌
Survives an accidental git add . βœ… ❌

What this does not cover, so you can judge for yourself:

  • To switch account, supawho runs supabase login --token <token>. For that brief moment the token is visible in the process list to other processes running as your user.
  • After the switch, the Supabase CLI keeps the active token in its own storage: the OS keyring when available, otherwise a plain-text file under ~/.supabase.
  • The only file supawho writes is a timestamp for the daily update check. It contains no token.

The full picture is in the security model.


πŸ“‹ Requirements

  • macOS, Linux, or Windows β€” a single static binary, no runtime to install
    • On Linux, a Secret Service provider must be running (GNOME Keyring, KWallet, …)
  • Supabase CLI β€” installed and available in your PATH

πŸ›  Troubleshooting

Account not found when running supawho use Run supawho list to check the exact name β€” account names are case-sensitive.

The token stops working after switching Confirm it's still valid in Supabase Dashboard β†’ Access Tokens, then run supawho add again with the same name and a fresh token: it replaces the saved one.

Linux: Cannot create an item in a locked collection Your keyring is locked or no Secret Service is running. Unlock your login keyring (GNOME Keyring / KWallet) and try again.

supawho upgrade says it's managed by a package manager That's on purpose β€” update through the manager you installed it with (see the table above).

More cases, with the exact error messages, are in the troubleshooting guide.


🀝 Contributing

Issues, ideas and PRs are welcome β€” this project grew cross-platform thanks to the community. Special thanks to @igorgomes3 whose supawho-linux fork sparked the multi-OS rewrite.

Found a bug or want a feature? Open an issue.


πŸ“„ License

MIT β€” Made with πŸ’š by Elia Tolin

About

CLI to switch between multiple Supabase accounts: save each account once, then switch the Supabase CLI with one command. Tokens stay in the OS keychain. macOS, Linux, Windows.

Topics

Resources

Stars

32 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages