npm install -g rebase

CLI & Tooling

One command to scaffold. One command to generate schemas. One command to deploy. The Rebase CLI handles the full lifecycle of your project.

From zero to admin panel in 60 seconds

# 1. Scaffold a new project
$ npx create-rebase-app ./my-admin

# 2. Configure your DATABASE_URL in .env
$ echo "DATABASE_URL=postgres://..." > .env

# 3. Generate schema from your database
$ rebase db pull
 Introspected 12 tables, 3 enums

# 4. Generate the client SDK types
$ rebase generate-sdk
 Generated database.types.ts

# 5. Start developing
$ rebase dev
 Frontend:  http://localhost:5173
 Backend:   http://localhost:3001
 GraphiQL:  http://localhost:3001/api/graphiql
 Swagger:   http://localhost:3001/api/swagger

Command Reference

Every command you need, from scaffolding to production migration.

Create

@rebasepro/create
$ npx create-rebase-app ./my-app

Scaffold a new Rebase project with frontend, backend, and shared collections. Interactive prompts for database URL and options.

Schema Generate

schema
$ rebase schema generate

Read your TypeScript collection definitions and generate a Drizzle ORM schema file. Run this after adding or modifying collections.

DB Push

db
$ rebase db push

Apply the current Drizzle schema directly to your database. A development shortcut that skips migration files.

DB Pull

db
$ rebase db pull

Introspect your live PostgreSQL database and reverse-engineer a Drizzle schema from existing tables, columns, and relations.

DB Generate

db
$ rebase db generate

Compare your current Drizzle schema against the last snapshot and generate SQL migration files for the differences.

DB Migrate

db
$ rebase db migrate

Run all pending SQL migrations against your database. Safe for production deployments.

Generate SDK

sdk
$ rebase generate-sdk

Generate a fully-typed database.types.ts file from your collection definitions. Use with createRebaseClient<Database>() for end-to-end type safety.

Dev Server

dev
$ rebase dev

Start the frontend and backend concurrently in development mode with hot reload.

Auth Bootstrap

auth
$ rebase auth bootstrap

Create the first admin user and set up the authentication tables. One-time setup for new projects.

The Rebase Workflow

Collections are the source of truth. Everything flows from them.

📝

Define Collections

TypeScript

⚙️

Generate Schema

rebase schema generate

🚀

Push & Deploy

rebase db push

Generates → REST + GraphQL APIs

Generates → Admin UI

Generates → Typed Client SDK

Get started in one command

$ npx create-rebase-app ./my-app