You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Getting started: single dominant golden path, collapsed alternate setups, CodeRabbit fixes
Landing page hierarchy per product feedback (too many competing paths):
- Hero pitch now defines Prisma before naming versions, keeps one primary
CTA (tutorial); secondary CTA becomes "Prisma 7 docs" so existing users
exit early without a competing journey. Stack layers link to product
overviews instead of three different setup flows.
- One-line bridge above the tabs card ties it to the tutorial (same
journey, condensed); CLI deploy step discloses the free-account sign-in.
- Framework picker reframed as a step in the same journey; SvelteKit/Deno
local-only caveat stated up front instead of inside the prompt only.
- Prisma 7 section moved above alternates; five alternate-path prompt rows
now sit behind a native <details> disclosure (content stays in static
HTML and .md output, keyboard accessible).
- /next drops the duplicate "What you can try" card block; /next/getting-started
drops the duplicate Prisma Postgres section; /getting-started leads with
the recommended quickstart and folds deploy into its own section.
- Fill empty Prerequisites on the Prisma 7 Prisma Postgres quickstart.
CodeRabbit findings:
- Template-to-guide slug mapping in the deploy step of the hero prompt
(next/nest/svelte no longer produce dead .md URLs).
- Framework guide prompts run the dev server in the background, wait for
readiness, and stop it after verification.
- TanStack Start guide: garbled npm fence replaced with `npm install nitro`.
- llm-markdown: fenced code is protected before all component transforms
(prefix-aware restore replays dedent/blockquote shifts on fence lines),
and GetStartedTabs parses via the brace-aware component parser so `>`
inside the cli template literal cannot truncate the match.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: apps/docs/content/docs/(index)/getting-started.mdx
+18-39Lines changed: 18 additions & 39 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,60 +6,44 @@ metaTitle: Prisma 7 getting started
6
6
metaDescription: Choose the fastest Prisma 7 setup path. Quickstarts and existing-project guides for Prisma ORM 7, Prisma Postgres, and Prisma Compute, plus an agent prompt.
7
7
---
8
8
9
-
Prisma 7 is the current generally available release of Prisma ORM, and `npx prisma@latest init` installs it. This page collects the Prisma 7 starting points: deploy an app, create a database, use Prisma ORM locally, or add Prisma to an existing project.
9
+
Prisma 7 is the current generally available release of Prisma ORM, and `npx prisma@latest init` installs it. This page collects the Prisma 7 starting points: start a new project, add Prisma to an existing one, then deploy.
10
10
11
11
:::note
12
12
13
-
Starting a new project? [Prisma Next](/next) is the recommended path for new apps. It is the next major version of Prisma ORM (soon Prisma 8), available now in Early Access. The [getting started page](/)walks the full stack path.
13
+
Starting a new project? [Prisma Next](/next) is the recommended path for new apps. It is the next major version of Prisma ORM (soon Prisma 8), available now in Early Access. The [getting started page](/)covers it.
14
14
15
15
:::
16
16
17
-
## Choose your path
17
+
## Start a new project
18
18
19
-
### Deploy a full-stack app with a database
19
+
The recommended path is the [Quickstart with Prisma Postgres](/prisma-orm/quickstart/prisma-postgres): it provisions a managed PostgreSQL database for you and gets you from install to first query in about five minutes.
20
20
21
-
Use this path if you want to deploy a TypeScript app with Prisma Compute and run it alongside Prisma Postgres.
21
+
Working with a specific database instead?
22
22
23
-
-[Deploy your first app](/prisma-compute/deploy) on [Prisma Compute](/compute), currently in Public Beta, to run it next to your Prisma Postgres database
24
-
25
-
### Start a new project
26
-
27
-
Use this path if you are creating a new app and want to set up Prisma from the beginning.
28
-
29
-
-[Quickstart with Prisma Postgres](/prisma-orm/quickstart/prisma-postgres) for the fastest end-to-end path with a managed PostgreSQL database
30
-
-[Quickstart with PostgreSQL](/prisma-orm/quickstart/postgresql) if you want to work with PostgreSQL
23
+
-[Quickstart with PostgreSQL](/prisma-orm/quickstart/postgresql)
31
24
-[Quickstart with SQLite](/prisma-orm/quickstart/sqlite) for a lightweight local setup
32
-
-[Quickstart with MySQL](/prisma-orm/quickstart/mysql) if your application uses MySQL
33
-
-[Quickstart with MongoDB](/prisma-orm/quickstart/mongodb) if your application uses MongoDB
25
+
-[Quickstart with MySQL](/prisma-orm/quickstart/mysql)
26
+
-[Quickstart with MongoDB](/prisma-orm/quickstart/mongodb)
34
27
35
-
###Add Prisma to an existing project
28
+
## Add Prisma to an existing project
36
29
37
-
Use this path if you already have an application or database and want to add Prisma ORM.
30
+
Use these guides if you already have an application or database and want to add Prisma ORM:
38
31
39
32
-[Add Prisma ORM to an existing PostgreSQL project](/prisma-orm/add-to-existing-project/postgresql)
40
33
-[Add Prisma ORM to an existing MySQL project](/prisma-orm/add-to-existing-project/mysql)
41
34
-[Add Prisma ORM to an existing SQLite project](/prisma-orm/add-to-existing-project/sqlite)
42
35
-[Add Prisma ORM to an existing MongoDB project](/prisma-orm/add-to-existing-project/mongodb)
43
36
-[Add Prisma ORM to an existing Prisma Postgres project](/prisma-orm/add-to-existing-project/prisma-postgres)
44
37
45
-
## What you will do
46
-
47
-
Most Prisma ORM and Prisma Postgres guides follow the same basic flow:
38
+
## Deploy to Prisma Compute
48
39
49
-
1. Define a database connection and data model in your [Prisma schema](/orm/prisma-schema/overview).
50
-
2. Set up your database, either with [Prisma Postgres](/postgres) or another supported database.
51
-
3. Install Prisma CLI and [Prisma Client](/orm/prisma-client).
52
-
4. Run `prisma generate` to create a type-safe client for your schema.
53
-
5. Create or introspect your database.
54
-
6. Start sending queries from your application.
55
-
56
-
Then you can deploy your app to [Prisma Compute](/compute). The flow is:
40
+
Once your app runs locally, [Prisma Compute](/compute) (currently in Public Beta) runs it next to your Prisma Postgres database:
57
41
58
42
1. Sign in with `npx @prisma/cli@latest auth login`.
59
-
2. Run `npx @prisma/cli@latest app deploy` from your app directory to get a live URL.
60
-
3.Connect your app to [Prisma Postgres](/postgres)or another database with [environment variables](/compute/environment-variables).
61
-
4. Redeploy to apply the environment variables.
62
-
5. Keep deploying from the CLI, or [connect GitHub](/compute/github) to deploy on push.
43
+
2. Run `npx @prisma/cli@latest app deploy` from your app directory to get a live URL, adding `--env .env` so environment variables like `DATABASE_URL` reach the deployment.
44
+
3.Keep deploying from the CLI, or [connect GitHub](/compute/github) to deploy on push.
45
+
46
+
The [deploy guide](/prisma-compute/deploy) covers build settings, frameworks, and troubleshooting.
63
47
64
48
## Use with your agent
65
49
@@ -87,12 +71,7 @@ Current docs: https://www.prisma.io/docs/getting-started.md and https://www.pris
87
71
After setup, these pages are usually the next ones people need:
Copy file name to clipboardExpand all lines: apps/docs/content/docs/(index)/index.mdx
+32-22Lines changed: 32 additions & 22 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,35 +10,37 @@ full: true
10
10
11
11
<HeroGrid>
12
12
<HeroPitch
13
-
badge="Recommended"
13
+
badge="Recommended path"
14
14
primaryHref="/next/full-stack-tutorial"
15
15
primaryLabel="Start the full-stack tutorial"
16
-
secondaryHref="/prisma-compute/deploy"
17
-
secondaryLabel="Deploy your first app"
16
+
secondaryHref="/getting-started"
17
+
secondaryLabel="Prisma 7 docs"
18
18
>
19
-
Build and ship with the complete Prisma stack: [Prisma Next](/next) (soon Prisma 8) to model and query your data, [Prisma Postgres](/postgres) to store it, and [Prisma Compute](/compute) to run your app next to it. One scaffold command wires up all three, for you and your coding agent.
19
+
Prisma is a complete TypeScript stack for building with data: [Prisma ORM](/orm)to model and query it, [Prisma Postgres](/postgres) to store it, and [Prisma Compute](/compute) to run your app next to it. Start new projects with [Prisma Next](/next), the next major version of the ORM and soon Prisma 8: one scaffold command wires up all three, for you or your coding agent.
20
20
</HeroPitch>
21
21
<StackDiagramcaption="One project. Type-safe, end to end.">
The tutorial's journey, condensed: hand the prompt to your coding agent, or run the CLI steps yourself.
35
+
34
36
<GetStartedTabscli={`# Scaffold the app
35
37
npx create-prisma@next
36
38
# Initialize, seed, and run
37
39
cd my-app
38
40
npm run db:init
39
41
npm run db:seed
40
42
npm run dev
41
-
# Deploy to a live URL
43
+
# Deploy to a live URL (free account, browser sign-in)
42
44
npx @prisma/cli@latest app deploy --env .env`}>
43
45
44
46
```text
@@ -50,14 +52,14 @@ If I have not told you which framework, stop and ask before scaffolding. Valid -
50
52
2. From the project directory, apply the starter contract and seed: `npm run db:init`, then `npm run db:seed`. If seeding fails with `Cannot read properties of undefined (reading 'where')`, change `db.orm.User` to `db.orm.public.User` in `src/prisma/seed.ts`, `src/prisma/users.ts`, and any route files that query `db.orm`, then rerun.
51
53
3. Edit the starter contract under `src/prisma/` into a small schema for my use case, then run `npm run contract:emit` and plan and apply the migration: `npx prisma-next migration plan`, then `npx prisma-next migrate --yes`. Migration planning diffs the emitted contract, so the emit step is required.
52
54
4. Update the seed script and the app routes to query the new schema, start `npm run dev` in the background, and verify with a request against the running app. For the `nest` template, if routes return 500s with `reading 'findAll'` in the logs, add explicit `@Inject()` tokens as shown in https://www.prisma.io/docs/guides/next/frameworks/nestjs.md.
53
-
5. Deploy with Prisma Compute. First apply the framework's deploy requirement from https://www.prisma.io/docs/guides/next/frameworks/[framework].md: Next.js needs `output: "standalone"` in `next.config.ts` (without it the deployed app returns 504s), TanStack Start needs the nitro build plugin, Astro needs the `@astrojs/node` adapter plus `--env HOST=0.0.0.0`, and Elysia needs `--framework bun --entry src/index.ts` on the deploy command. If the template is `svelte`, skip this step; Compute does not support SvelteKit yet. Check `npx @prisma/cli@latest auth whoami`. If I am not signed in, stop and ask me to run `npx @prisma/cli@latest auth login`, because that step opens a browser. Then run `npx @prisma/cli@latest app deploy --env .env` so DATABASE_URL reaches the deployment, and verify the deployed URL with curl.
55
+
5. Deploy with Prisma Compute. First apply the framework's deploy requirement from the guide at https://www.prisma.io/docs/guides/next/frameworks/[guide].md, where [guide] is the template name except: template `next` → guide `nextjs`, `nest` → `nestjs`, `svelte` → `sveltekit`. The requirements: Next.js needs `output: "standalone"` in `next.config.ts` (without it the deployed app returns 504s), TanStack Start needs the nitro build plugin, Astro needs the `@astrojs/node` adapter plus `--env HOST=0.0.0.0`, and Elysia needs `--framework bun --entry src/index.ts` on the deploy command. If the template is `svelte`, skip this step; Compute does not support SvelteKit yet. Check `npx @prisma/cli@latest auth whoami`. If I am not signed in, stop and ask me to run `npx @prisma/cli@latest auth login`, because that step opens a browser. Then run `npx @prisma/cli@latest app deploy --env .env` so DATABASE_URL reaches the deployment, and verify the deployed URL with curl.
54
56
55
57
Use the installed Prisma Next skills and the current Prisma docs: https://www.prisma.io/docs/llms.txt (append `.md` to any docs URL for a markdown version).
56
58
```
57
59
58
60
</GetStartedTabs>
59
61
60
-
<SectionRowtitle="Add Prisma to your framework"description="Every guide covers the same journey: scaffold, connect Prisma Postgres, run a real query, and deploy where the framework is supported on Compute.">
62
+
<SectionRowtitle="Pick your framework"description="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](/next/add-to-existing-project/postgresql). The [full-stack tutorial](/next/full-stack-tutorial) walks the whole journey step by step with expected output.
77
+
If you're using Express or another Node.js server, follow the [existing-project path](/next/add-to-existing-project/postgresql) instead.
78
+
79
+
</SectionRow>
80
+
81
+
<SectionRowtitle="Using Prisma 7?"description="Prisma 7 is the current generally available release of Prisma ORM, fully supported, and `npx prisma@latest init` installs it. It pairs with Prisma Postgres and Prisma Compute the same way. When you're ready, Prisma Next is the path to Prisma 8.">
82
+
83
+
<IconGrid>
84
+
<IconLinkhref="/getting-started"title="Prisma 7 setup paths"description="All database quickstarts, plus the agent prompt"icon={<Milestone />} />
<SectionRowtitle="More setup paths"description="Each path has a guide to follow and a prompt to hand to your agent.">
90
+
<SectionRowtitle="Other setups"description="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.">
91
+
92
+
{/* Native <details> keeps the collapsed paths in the static HTML for crawlers
93
+
and agents, and stays keyboard-accessible without client JS. */}
<summaryclassName="cursor-pointer select-none py-2.5 text-sm font-medium text-fd-foreground marker:text-fd-muted-foreground hover:text-fd-primary">Existing project, your own database, or a single product (ORM, Postgres, or Compute) on its own</summary>
80
97
81
98
<AgentPrompttitle="Add Prisma to an existing project"guideHref="/next/add-to-existing-project/postgresql"guideTitle="PostgreSQL guide"icon={<FolderPlus />}>
82
99
@@ -159,14 +176,7 @@ Current docs: https://www.prisma.io/docs/prisma-compute/deploy.md.
159
176
160
177
If you're using MongoDB, follow the [MongoDB quickstart](/next/quickstart/mongodb) or [add Prisma Next to an existing MongoDB app](/next/add-to-existing-project/mongodb). If you work with [Kysely](/prisma-postgres/quickstart/kysely), [Drizzle](/prisma-postgres/quickstart/drizzle-orm), or [TypeORM](/prisma-postgres/quickstart/typeorm), the Prisma Postgres quickstarts cover those tools.
161
178
162
-
</SectionRow>
163
-
164
-
<SectionRowtitle="Using Prisma 7?"description="Prisma 7 is the current generally available release of Prisma ORM, and `npx prisma@latest init` installs it. It pairs with Prisma Postgres and Prisma Compute the same way. When you're ready, Prisma Next is the path to Prisma 8.">
165
-
166
-
<IconGrid>
167
-
<IconLinkhref="/getting-started"title="Prisma 7 setup paths"description="All database quickstarts, plus the agent prompt"icon={<Milestone />} />
0 commit comments