Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions apps/docs/content/docs/(index)/full-stack-tutorial.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ It uses the `hono` template so you get a small API you can verify with curl at e

## Prerequisites

- Node.js 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended), or Bun
- Node.js 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended), or Bun
- npm 11.6.0 or newer, if you use npm. Node.js 22 comes with npm 10, so run `npm install --global npm@11` first; the [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why
- A [Prisma Data Platform account](https://pris.ly/pdp) for the deploy step, free to create, with no credit card needed on the [Free plan](#what-the-free-plan-includes)
- No database needed: local runs provision a local Prisma Postgres, and deploys provision a real one, both from your Composer declaration
Expand Down Expand Up @@ -74,7 +74,7 @@ The prompt uses npm and Node.js. On Bun, replace `npm create prisma@latest --` w
```text
Create a new Hono API composed with Prisma Composer and Prisma ORM, run it locally, and deploy it to Prisma Compute.

Check the versions first: `node --version` must print 22.18 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.
Check the versions first: `node --version` must print 22.22 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.

1. Scaffold: `npm create prisma@latest -- my-app --template hono --provider postgres --yes`. Then run `npx prisma@latest init` in `my-app` to confirm the Prisma agent skills the scaffold installed are current, and use them.
2. Read `module.ts` and `service.ts` first: the Composer module provisions the database and the service, and it is what `dev` and `deploy` operate on.
Expand Down
7 changes: 4 additions & 3 deletions apps/docs/content/docs/(index)/getting-started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ Coming from an earlier version? [Coming from Prisma ORM 7](/orm/coming-from-pris

## Prerequisites

- **Node.js 22.18 or newer; on the 24 line, 24.11 or newer.** Check with `node --version`. Node.js 24 is recommended.
- **npm 11.6.0 or newer, if you start a new project with npm.** Check with `npm --version`. Node.js 22 comes with npm 10, and `npm create prisma@latest` stops on npm 10 before it writes any files, so update npm first with `npm install --global npm@11`. pnpm, Bun, and Yarn 2 or newer are also supported. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) have the details.
- **Prisma ORM: Node.js 22.18 or newer.** Check with `node --version`. Node.js 24 is recommended.
- **Creating a new app with `create-prisma`: Node.js 22.22 or newer; on the 24 line, 24.11 or newer.** This is the scaffolding tool's requirement, not Prisma ORM's minimum. See the [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites).
- **npm 11.6.0 or newer, if you start a new project with npm.** Check with `npm --version`. Node.js 22 comes with npm 10, and `npm create prisma@latest` stops on npm 10 before it writes any files, so update npm first with `npm install --global npm@11`. pnpm, Bun, and Yarn 4.10 or newer are also supported. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) have the details.

## Start a new project

Expand Down Expand Up @@ -70,7 +71,7 @@ Create a new [framework] application with Prisma ORM, seed it, and run it locall

If I have not told you which framework, stop and ask before scaffolding. Valid --template values: minimal (the default), next, hono, nuxt, astro, nest, svelte, tanstack-start, elysia.

Check the versions first: `node --version` must print 22.18 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.
Check the versions first: `node --version` must print 22.22 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.

1. Scaffold the app: `npm create prisma@latest -- my-app --template [framework] --provider postgres --yes`.
2. Get a database connection string: use the one I give you, or create a Prisma Postgres database with `npx create-db@latest` and show me the claim URL it prints. Export it as `DATABASE_URL` in the shell; the generated scripts read the environment variable, not `.env`.
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/(index)/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ Create a new [framework] application with Prisma ORM against my existing Postgre

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

Check the versions first: `node --version` must print 22.18 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.
Check the versions first: `node --version` must print 22.22 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.

1. Scaffold: `npm create prisma@latest -- 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.
Expand Down
11 changes: 8 additions & 3 deletions apps/docs/content/docs/(index)/prisma-orm/create-prisma.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ Use it when you want to start from a working app. If you already have an app, fo

Check both versions before you run the command, because `create-prisma` stops when either one is too old:

- **Node.js 22.18 or newer; on the 24 line, 24.11 or newer.** Check with `node --version`. Node.js 24 is recommended.
These are `create-prisma`'s requirements. Prisma ORM itself supports Node.js 22.18 or newer; see [release status](/orm/release-status).

- **Node.js 22.22 or newer; on the 24 line, 24.11 or newer.** Check with `node --version`. Node.js 24 is recommended.
- **npm 11.6.0 or newer, if you install with npm.** Check with `npm --version`. Every Node.js 22 release comes with npm 10, so on Node.js 22 you have to update npm yourself. Node.js 24.11 and newer already come with a new enough npm.

To update npm:
Expand All @@ -35,7 +37,9 @@ Older npm releases can crash while they install the Prisma packages. For that re
Create command failed: npm 10.9.9 is unsupported. Required: npm 11.6.0 or newer. Older npm releases can crash while resolving Prisma dependencies. Run npm install --global npm@11, then retry create-prisma.
```

The npm requirement applies only when npm installs the project. pnpm, Bun, and Yarn 2 or newer are also supported, but Yarn 1 is not.
The npm requirement applies only when npm installs the project. pnpm, Bun, and Yarn 4.10 or newer are also supported.

Some framework templates require a newer Node.js version. The Nuxt template requires Node.js 22.22.3 or newer on the 22 line, 24.15 or newer on the 24 line, or 26 or newer. Check the generated `package.json` for the template's `engines` field.

## Create a project

Expand Down Expand Up @@ -85,6 +89,7 @@ npm create prisma@latest -- my-app --template next --provider postgres --yes
| `--template` | App |
| --- | --- |
| `minimal` | A minimal server with one query |
| `turborepo` | A Hello World server and shared Prisma package in a Turborepo workspace |
| `next` | Next.js |
| `hono` | Hono |
| `elysia` | Elysia |
Expand All @@ -106,7 +111,7 @@ Deno 2.9 skips packages published in the previous 24 hours by default, so withou

## Start the app

Set the connection string in your environment, then initialize the database and start the dev server. The generated `prisma.config.ts` reads `DATABASE_URL` for PostgreSQL and `MONGODB_URL` for MongoDB from the process environment and loads no dotenv file (Deno projects are the exception: their scripts pass `--env-file=.env`), so export the variable in the shell before running the scripts.
Set the connection string in your environment, then initialize the database and start the dev server. The generated `prisma.config.ts` reads `DATABASE_URL` for both PostgreSQL and MongoDB from the process environment and loads no dotenv file (Deno projects are the exception: their scripts pass `--env-file=.env`), so export the variable in the shell before running the scripts.

```bash
cd my-app
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/(index)/prisma-orm/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ Create a new [framework] application with Prisma ORM, seed it, and run it locall

If I have not told you which framework, stop and ask before scaffolding. Valid --template values: minimal (the default), next, hono, nuxt, astro, nest, svelte, tanstack-start, elysia.

Check the versions first: `node --version` must print 22.18 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.
Check the versions first: `node --version` must print 22.22 or newer (on the 24 line, 24.11 or newer). If you use npm, `npm --version` must print 11.6.0 or newer; Node.js 22 comes with npm 10, so if npm is older, run `npm install --global npm@11` before step 1.

1. Scaffold the app: `npm create prisma@latest -- my-app --template [framework] --provider postgres --yes`. Then run `npx prisma@latest init` in the project directory so the Prisma agent skills are installed and stay current, and use them.
2. Get a database connection string: use the one I give you, or create a Prisma Postgres database in the project the app will deploy to: check `npx prisma auth whoami` (if I am not signed in, stop and ask me to run `npx prisma auth login`), then `npx prisma project create my-app` and `npx prisma postgres create mydb`, which prints the connection string once. Export it as `DATABASE_URL` in the shell; the generated scripts read the environment variable.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ For what release candidate means, when the final release is expected, and how to

## Quick start

You need Node.js 22.18 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.
You need Node.js 22.22 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.

```npm
npm create prisma@latest -- --provider mongodb --no-deploy
Expand All @@ -40,11 +40,10 @@ The scaffold writes a `.env` with a local replica-set connection string:
DATABASE_URL="mongodb://localhost:27017/mydb?replicaSet=rs0&directConnection=true"
```

The generated scripts read environment variables directly rather than `.env`, and the CLI and the app use different variable names: the CLI commands read `MONGODB_URL`, and the app reads `DATABASE_URL`. Export both in the shell you work in:
The generated scripts read `DATABASE_URL` directly from the environment rather than `.env`. Export it in the shell you work in:

```bash
export MONGODB_URL="mongodb://localhost:27017/mydb?replicaSet=rs0&directConnection=true"
export DATABASE_URL="$MONGODB_URL"
export DATABASE_URL="mongodb://localhost:27017/mydb?replicaSet=rs0&directConnection=true"
```

If you use MongoDB Atlas, use the connection string from your Atlas cluster instead.
Expand All @@ -67,7 +66,7 @@ Apply the planned migration to MongoDB.
npm run migrate
```

The output ends with a summary like `Applied 3 operation(s) across 1 contract space`. If it fails with a connection error, confirm `MONGODB_URL` is exported in this shell and points at a running MongoDB deployment; if the string still names `replicaSet=rs0`, that replica set has to exist.
The output ends with a summary like `Applied 3 operation(s) across 1 contract space`. If it fails with a connection error, confirm `DATABASE_URL` is exported in this shell and points at a running MongoDB deployment; if the string still names `replicaSet=rs0`, that replica set has to exist.

The `1 contract space` in the summary is the migration history for your own models. Prisma ORM calls it the `app` [contract space](/orm/migrations/the-migration-graph#terms-used-on-this-page), and its migrations are in `migrations/app/`.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ For what release candidate means, when the final release is expected, and how to

## Quick start

You need Node.js 22.18 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.
You need Node.js 22.22 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.

```npm
npm create prisma@latest -- --provider postgres --no-deploy
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Use the CLI when you want Prisma ORM and Prisma Postgres set up without leaving

## Start a new app

You need Node.js 22.18 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.
You need Node.js 22.22 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.

```npm
npm create prisma@latest
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Create a Prisma ORM app backed by Prisma Postgres.

## Quick start

You need Node.js 22.18 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.
You need Node.js 22.22 or newer (on the 24 line, 24.11 or newer); Node.js 24 is recommended. If you use npm, you also need npm 11.6.0 or newer: Node.js 22 comes with npm 10, so run `npm install --global npm@11` first. The [create-prisma prerequisites](/prisma-orm/create-prisma#prerequisites) explain why.

```npm
npm create prisma@latest
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/guides/frameworks/astro.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Answer the prompts, then export `DATABASE_URL` in your shell before running the

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- [Node.js](https://nodejs.org) 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- A PostgreSQL connection string, or nothing at all: `npx create-db@latest` can create a Prisma Postgres database for you

## 1. Scaffold and enter the project
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/guides/frameworks/hono.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Every command, route, and response below was run end to end against a live Prism

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended), or [Bun](https://bun.sh/) (this guide uses Bun for speed; npm works the same)
- [Node.js](https://nodejs.org) 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended), or [Bun](https://bun.sh/) (this guide uses Bun for speed; npm works the same)
- A PostgreSQL connection string, or nothing at all: the scaffold can create a [Prisma Postgres](/postgres) database for you

## 1. Scaffold the project
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/guides/frameworks/nestjs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Every command below was run end to end against a live [Prisma Postgres](/postgre

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- [Node.js](https://nodejs.org) 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- A PostgreSQL connection string, or nothing at all: `npx create-db@latest` can create a Prisma Postgres database for you

## 1. Scaffold and enter the project
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/guides/frameworks/nextjs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Every command below was run end to end against a live [Prisma Postgres](/postgre

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- [Node.js](https://nodejs.org) 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- A PostgreSQL connection string, or nothing at all: `npx create-db@latest` can create a Prisma Postgres database for you

## 1. Scaffold and enter the project
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/guides/frameworks/nuxt.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Answer the prompts, then export `DATABASE_URL` in your shell before running the

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- [Node.js](https://nodejs.org) 22.22.3 or newer on the 22 line, 24.15 or newer on the 24 line, or 26 or newer
- A PostgreSQL connection string, or nothing at all: `npx create-db@latest` can create a Prisma Postgres database for you

## 1. Scaffold and enter the project
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/guides/frameworks/sveltekit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Answer the prompts, then export `DATABASE_URL` in your shell before running the

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- [Node.js](https://nodejs.org) 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- A PostgreSQL connection string, or nothing at all: `npx create-db@latest` can create a Prisma Postgres database for you

## 1. Scaffold and enter the project
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Answer the prompts, then export `DATABASE_URL` in your shell before running the

## Prerequisites

- [Node.js](https://nodejs.org) 22.18 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- [Node.js](https://nodejs.org) 22.22 or newer (on the 24 line, 24.11 or newer; 24 recommended)
- A PostgreSQL connection string, or nothing at all: `npx create-db@latest` can create a Prisma Postgres database for you

## 1. Scaffold and enter the project
Expand Down
Loading