Overview
Prisma CLI reference
Prisma 8 ships with a unified Prisma CLI. One binary contains the ORM commands and the platform commands for Prisma Composer, Prisma Compute, Prisma Postgres, and object-store buckets.
Prisma 8 is the current release of Prisma ORM. Prisma 7 remains fully supported; its docs live at /orm/v7 and its setup paths at /v7/getting-started.
The Prisma 8 CLI ships in the prisma package. Run it without installing:
bunx prisma@latest --help
bunx prisma@latest contract emitWith prisma installed in your project, these commands become plain prisma contract emit and so on.
For a full app scaffold, use a Prisma 8 quickstart. That path creates the project files and package scripts for you. This CLI reference is for the lower-level commands those scripts call.
Platform commands
The platform commands manage the services, databases, and buckets your app runs on. With deploy and dev you deploy a Prisma Composer app to Prisma Compute and run it locally; with service and git you manage services, their versions, logs, and domains, and the repository connection. With postgres you spin up and manage Prisma Postgres databases. With bucket you create blob-storage buckets and their access keys. auth, project, and branch handle the account, project, and branch plumbing around them. Each command group has its own page in this section. Deployments are created by a git push to the connected repository, the Console, or deploy, and each deploy produces a service version.
Common workflows
There are two main entry points. Platform users deploy apps, create databases, and provision buckets with the platform commands. ORM users manage their schema, contracts, and migrations with the ORM and migration commands.
Deploy an app
Sign in, create or link a project, and connect the repository; every push then deploys. A Prisma Composer app deploys directly with deploy:
bunx prisma@latest auth login
bunx prisma@latest project create my-app
bunx prisma@latest git connect
bunx prisma@latest deploy module.tsFollow a deploy with service logs and manage the result with the service commands.
Create a database
bunx prisma@latest postgres create mydb
bunx prisma@latest postgres connection create mydbpostgres create prints a one-time connection URL; postgres connection create mints another when you need one. See postgres.
Create a bucket
bunx prisma@latest bucket create --name my-bucket
bunx prisma@latest bucket key create <bucket-id>bucket key create prints the key's one-time credentials. See bucket.
Start in an existing project
bunx prisma@latest orm init --target postgres --authoring psl
bunx prisma@latest contract emit
bunx prisma@latest db init --db "$DATABASE_URL"Adopt an existing database
bunx prisma@latest contract infer --db "$DATABASE_URL" --output ./prisma/contract.prisma
bunx prisma@latest contract emit
bunx prisma@latest db sign --db "$DATABASE_URL"
bunx prisma@latest db verify --db "$DATABASE_URL"Use checked-in migrations
bunx prisma@latest contract emit
bunx prisma@latest migration plan --name add-users
bunx prisma@latest migration status --db "$DATABASE_URL"
bunx prisma@latest db migrate --db "$DATABASE_URL"
bunx prisma@latest db verify --db "$DATABASE_URL"Agent skills
Prisma packages ship agent skills: instructions that teach AI coding agents the installed version's commands and APIs. init prepares a repository once, and skills sync keeps the installed copies matching your package versions.
bunx --bun prisma@latest init
bunx prisma@latest skills syncOther commands
A few commands ship without dedicated pages yet. contract format formats your PSL contract source in place, and lsp starts the Prisma 8 language server (spawned by editors, not run interactively). The migration group also has read-only inspection commands: migration list (on-disk migrations per contract space; --space, --ascii, --legend), migration log (executed history from the database ledger; --db, --utc, --ascii), migration graph (graph topology; --space, --dot for Graphviz output, --ascii, --legend), and migration check [target] (artifact and graph integrity; --space). Run any of them with --help for the details.
Global flags
Every command accepts the same set of output, prompt, and config flags. They are documented on Global flags.
