Skip to main content
Skip to navigation

Install and authenticate the RevenueCat CLI

Install the RevenueCat CLI and connect it to your RevenueCat account

AIAsk AIChatGPTClaude

This article shows you how to install the RevenueCat CLI and connect it to your RevenueCat account. By the end, rc auth status will report your authenticated account and the project the CLI acts on.

Prerequisites

  • A RevenueCat account. If you don't have one, the CLI can create one for you with rc auth signup after you install it.
  • A RevenueCat project. If you don't have one, create one with rc projects create after authenticating, or see Projects.

The CLI ships as a native binary for macOS, Linux, and Windows, so there's no runtime requirement. Node.js is only needed if you install through npm.

Install the CLI

On macOS and Linux, install with Homebrew:

brew install RevenueCat/tap/rc

For CI, agent sandboxes, and React Native projects, install through npm instead. The package ships the same native binary; Node only dispatches to it:

npm install -g @revenuecat/cli

Both methods install the command as rc and revenuecat (the same binary); use whichever you prefer. Every command also runs without installing anything, via npx @revenuecat/cli <command>.

Download a binary directly

Binaries for macOS, Linux, and Windows (amd64 and arm64) are attached to each release on the releases page, with checksums.

Authenticate

Log in with your browser, or paste an API key when prompted:

rc auth login

The CLI acts with your RevenueCat account's permissions. See collaborator permissions for what each role can reach.

If you don't have an account yet, create one without leaving the terminal:

rc auth signup

For CI and scripts, skip the login flow and pass a RevenueCat API v2 secret key through the RC_API_KEY environment variable or the --api-key flag.

Select a project

Set the project the CLI acts on by default:

rc projects use

With no argument, this opens an interactive picker. Choose Ask me every time if you work across multiple projects and want to pick per command. You can also override the project per invocation: the --project-id flag takes highest precedence, then the RC_PROJECT_ID environment variable, then a .revenuecat.json file in the directory tree, then the profile default.

To keep separate credentials for staging and production, log in once per profile and name the profile per command:

rc auth login --profile staging
rc auth login --profile prod

rc --profile staging customers list
rc --profile prod customers list

Verify your setup

Confirm the CLI is authenticated and pointed at the right project:

rc auth status

This prints your auth state and cached account identity without changing anything. rc whoami is a shortcut for the same command.

Continue with guided setup

With the CLI installed and authenticated, rc setup walks the rest of the RevenueCat setup while you approve each step, and emits a prompt your coding agent can run non-interactively. If your project already exists, point it straight at a store:

rc setup apple app_abc # App Store Connect: create and upload keys
rc setup google app_xyz # Google Play: bootstrap and upload the service-account credential

The argument is the RevenueCat app ID (like app_abc), not a bundle ID or a store app ID. See the Setup commands for what each flow does, and the manual paths in App Store Connect API keys and Google Play service credentials if you'd rather create credentials yourself.

Next steps

Was this page helpful?