CLI
Install
Install the Fakebase CLI with npm, or run it with npx without installing.
Requirements
- Node.js 22 or later.
- Docker Desktop, if Fakebase should run PostgreSQL for you. You don't need Docker when you use a database you already have.
Install with npm
npm install -g @fakebase/cli
Check that it works:
fakebase --version
Run with npx
To use the CLI without installing it, put npx @fakebase/cli in front of any command instead of fakebase:
npx @fakebase/cli init --start
Update
npm install -g @fakebase/cli@latest
If you use Fakebase with a coding agent, run fakebase agent install afterwards and commit the changes, so your agent's instructions match the new version.
Check your setup
fakebase doctor
Checks your config, migrations folder, .gitignore, Docker, the database connection, and your migrations, and tells you how to fix anything that's wrong. It doesn't change anything.
Add --help to any command for its flags.