Prisma 8 is here.Read the docs

Get started with Prisma

Prisma is a complete TypeScript stack with one workflow: build your app and run all of it on your machine, then deploy it to the Prisma platform with one command. Jump straight to the full-stack tutorial, Prisma 8 or Prisma 7 docs.

Pick your framework

Every guide runs the same journey with the same commands: scaffold, connect Prisma Postgres, run a real query, and deploy. SvelteKit and Deno don't deploy to Compute yet; their guides stop at a verified local run.

If you're using Express or another Node.js server, follow the existing-project path instead.

Using Prisma 7?

Prisma 7 remains fully supported. Scaffold it with npx create-prisma@stable, or add it to an existing project with npx prisma@7.10.0 init. It pairs with Prisma Postgres and Prisma Compute the same way. When you're ready, Prisma 8 is the upgrade path.

Other setups

Already have an app or a database, or need a single Prisma product on its own? Each path has a guide to follow and a prompt to hand to your agent.

Existing project, your own database, or a single product on its ownFive paths: add to an existing project, bring your own Postgres, or use the ORM, Postgres, or Compute alone.
Other setup paths
Add Prisma to an existing projectPostgreSQL guide
Add Prisma to an existing project
Add Prisma 8 to this existing project.

This flow is for PostgreSQL. If the project uses MongoDB, follow https://www.prisma.io/docs/prisma-orm/add-to-existing-project/mongodb.md instead; for other databases, stop and tell me.

1. Run `npx prisma@latest orm init --yes --target postgres --authoring psl` (the flags are required when the CLI cannot prompt). It writes `prisma.config.ts`, a starter contract and `db.ts` under `src/prisma/`, and installs dependencies. Then run `npx prisma@latest skills sync` to install the Prisma 8 skills; `orm init` may end with `CLI.INIT_SKILL_INSTALL_FAILED`, which the sync repairs.
2. Set `DATABASE_URL` in `.env` to my database. If I did not give you one, create a Prisma Postgres database with `npx create-db@latest`, put its connection string in `.env`, and show me the claim URL it prints so I can keep the database.
3. If the database already has tables, infer the contract from it: `npx prisma@latest contract infer`, then `npx prisma@latest contract emit`, then sign it with `npx prisma@latest db sign`. If the database is empty, keep the starter contract and run `npx prisma@latest db init`.
4. Write one query with the generated `db` client in an existing code path, run it, and show me the returned rows.

Follow https://www.prisma.io/docs/prisma-orm/add-to-existing-project/postgresql.md and the installed Prisma 8 skills.
Prisma 8 with your own PostgreSQL databaseQuickstart
Prisma 8 with your own PostgreSQL database
Create a new [framework] application with Prisma 8 against my existing PostgreSQL database.

If I have not given you a connection string, stop and ask; do not invent one. Valid --template values: next, hono, nuxt, astro, nest, svelte, tanstack-start, elysia.

1. Scaffold: `npx create-prisma@latest create my-app --template [framework] --provider postgres --yes`.
2. Export my connection string as `DATABASE_URL` in the shell; the generated scripts read the environment variable, not `.env`. From the project directory: `npm run db:init`, then start `npm run dev` in the background and verify the sample query returns data. Sample users are seeded automatically on the app's first query; there is no separate seed script.
3. Evolve the starter contract under `src/prisma/` into my schema, then run `npm run contract:emit`, `npx prisma@latest migration plan`, and `npx prisma@latest db migrate --yes`.

Do not provision any hosted database. Use the installed Prisma 8 skills and https://www.prisma.io/docs/llms.txt for current docs.
Prisma ORM only (Prisma 7)Quickstart
Prisma ORM only (Prisma 7)
Add Prisma ORM 7 to this project with my existing database.

If I have not given you a database connection string and none exists in the project, stop and ask.

1. Run `npx prisma@7.10.0 init` (Prisma 7). For an existing database, set DATABASE_URL in `.env` and introspect it with `npx prisma db pull`; for a new schema, define models in `prisma/schema.prisma` and run `npx prisma migrate dev --name init`. If migrate dev asks to reset the database, stop and ask me first.
2. Install the driver adapter for the database (Prisma 7 requires one), e.g. `npm install @prisma/adapter-pg` for PostgreSQL, and pass it to `new PrismaClient({ adapter })`. Generate the client with `npx prisma generate` and write one query in an existing code path.
3. Run the query (e.g. with `npx tsx`) and show me the output, the schema, and the query you added.

Current docs: https://www.prisma.io/docs/orm/v7.md and https://www.prisma.io/docs/llms.txt.
Prisma Postgres onlycreate-db guide
Prisma Postgres only
Create a Prisma Postgres database for this project.

1. Run `npx create-db@latest`. It creates a temporary Prisma Postgres database without an account and prints a connection string plus a claim URL.
2. Put the connection string in `.env` as DATABASE_URL and wire it into whichever of Prisma ORM, Kysely, Drizzle, TypeORM, or node-postgres the project already uses (detect it from package.json; if none, ask me). Verify the connection with one trivial query such as `select 1`.
3. Remind me to open the claim URL to keep the database in my Prisma workspace.

Current docs: https://www.prisma.io/docs/postgres.md.
Prisma Compute onlyDeploy guide
Prisma Compute only
Deploy this app to Prisma Compute using `npx prisma@latest`.

Compute runs apps declared with Prisma Composer: your server code plus a small TypeScript declaration. Port the app following https://www.prisma.io/docs/composer/porting-an-app.md. SvelteKit and Deno are not supported yet; if the app is one of those, stop and tell me.

1. Install `@prisma/composer` and `@prisma/composer-prisma-cloud`, and pin `effect` in package.json to the exact version in `node_modules/@prisma/composer/package.json` (`"overrides": { "effect": "<that version>" }`). Then install the Composer skill with `npx prisma@latest skills sync`, and use it.
2. Declare the app: a `service.ts` with `compute({ name, deps, build })`, a `module.ts` that provisions it, and a `prisma-composer.config.ts`. Read the port from `service.port()` and bind 0.0.0.0. Replace other `process.env` reads with the service input schema, binding credentials like DATABASE_URL with `envSecret`. Composer does not build: produce one self-contained entry file per service (for example `esbuild <server> --bundle --platform=node --format=esm --outfile=dist/server.mjs`), or use the framework build adapter (Next.js needs the `nextjs` adapter and `output: "standalone"`).
3. Verify locally: run the build, then `npx prisma@latest dev module.ts`, and curl the printed local URL.
4. Confirm I am signed in with `npx prisma@latest auth whoami`; if not, stop and ask me to run `npx prisma@latest auth login` (it opens a browser).
5. Deploy: run the build, then `npx prisma@latest deploy module.ts` with the app's env values (like DATABASE_URL) exported in the shell; the first deploy copies input values up to the deployment. Verify the printed public URL with curl.

Current docs: https://www.prisma.io/docs/composer/porting-an-app.md and https://www.prisma.io/docs/prisma-compute/deploy.md.

If you're using MongoDB, follow the MongoDB quickstart or add Prisma 8 to an existing MongoDB app. If you work with Kysely, Drizzle, or TypeORM, follow the Prisma Postgres quickstart for that tool.

Browse the docs

This page hides the full navigation to keep the first run focused. Everything is one click away.