Skip to main content
skill Claude Code CX Codex Cursor GitHub Copilot

prisma-postgres-setup — Claude Code skill: what it does

Provisions or connects a Prisma Postgres database and links it to your app. Useful for spinning up dev databases quickly or wiring connections in Vercel and v0.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add prisma/skills --skill prisma-postgres-setup -a claude-code
Open on GitHub

What prisma-postgres-setup does

The skill inspects installed packages, drivers, and environment files without revealing secrets in chat. If a database connection is already configured, it reuses it instead of creating duplicates. For projects without an existing database, it offers either a persistent instance or a temporary one via npx create-db@latest. Temporary databases expire after 24 hours unless claimed with a free Prisma account.

Credentials stay in local environment files, kept out of version control through .gitignore. The skill hands Prisma ORM configuration off to prisma-orm-setup. If the project specifies another tool, such as Drizzle or the pg driver, it respects that setup and avoids forcing Prisma ORM.

Setup finishes with a read-only query to confirm connectivity. If permission limits or quotas block database provisioning, the process halts. The skill reports the blocker directly rather than switching workspaces or removing other resources.

What it helps with

  • provision an ephemeral database using npx create-db without an account
  • connect an existing Prisma Postgres instance to the application
  • configure database environment variables for Vercel projects and v0
  • verify database connectivity with a read-only query without exposing credentials

Example prompts for the agent

  • I need a database for this app
  • Add a Postgres database using npx create-db
  • Connect Prisma Postgres but keep Drizzle as the ORM

How to install prisma-postgres-setup

1Skills CLI (Vercel)

npx skills add prisma/skills --skill prisma-postgres-setup -a claude-code

2Manually: put the files in place

~/.claude/skills/prisma-postgres-setup/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/prisma-postgres-setup/

From the same set5

The whole set →

Similar

multi-cloud-architecture Seth Hobson This skill helps design systems across AWS, Azure, GCP, and OCI, compare services, and choose a migration or disaster recovery pattern. Claude Code CX Codex Cursor 10,700installs projection-patterns Seth Hobson Build read models from event streams with guidance on projection types and replay. Useful for CQRS read sides, materialized views, and search indexes. Claude Code CX Codex Cursor 10,500installs google-cloud-solution-hybrid-search-alloydb official google This skill helps design and validate AlloyDB hybrid search, combining semantic retrieval with keyword search and structured SQL filters. Claude Code Gemini CLI CX Codex 3,300installs google-cloud-storage-bucket-architect official google This skill plans and creates Google Cloud Storage buckets around a workload and the project's security settings. Use it when an app, service, or pipeline needs object storage. Claude Code Gemini CLI CX Codex 2,800installs xlsx official anthropics Creates, reads, edits, and converts spreadsheet files. Use it when the requested deliverable is an Excel workbook or another tabular file. Claude Code Claude.ai 187,223installs google-agents-cli-observability official Google This skill guides you through tracing and monitoring AI agents, including ADK agents. Use it when you need to inspect agent execution or monitor a deployed agent. Claude Code CX Codex Cursor +1 509,900installs caveman-evidence-review JuliusBrussee A read-only skill reviews Caveman Cloud evidence on LLM spend, traces, and routing. Use it to see where a project’s model budget goes. Claude Code CX Codex Cursor +1 103,500installs migration JuliusBrussee Enforces reversible, compatibility-safe transitions for schema, data, and API updates. Useful whenever data loss or rollout downtime is unacceptable. Claude Code CX Codex Cursor +1 102,900installs

Questions about prisma-postgres-setup

How to install prisma-postgres-setup in Claude Code?

Run npx skills add prisma/skills --skill prisma-postgres-setup -a claude-code. The file will be placed in ~/.claude/skills/prisma-postgres-setup/SKILL.md.

What does prisma-postgres-setup do?

It inspects your project environment, connects or provisions a Prisma Postgres database, and verifies the connection with a read-only query.

What happens to databases created with npx create-db?

Databases created without an account are deleted after 24 hours. You can keep them permanently by claiming them with a free Prisma account.

Source text

SKILL.md · MIT
---
name: prisma-postgres-setup
description: Obtain or reuse a Prisma Postgres database and connect an application. Use when the user needs a database and has none configured ("I need a database", "add a Postgres database", "set up a database for this app"), runs or mentions `create-db` or `npx create-db`, or asks to set up or connect Prisma Postgres, including in v0 and the Vercel Marketplace. Hands Prisma ORM configuration to prisma-orm-setup; reuses an existing connection first and honors an explicit provider, driver, alternative ORM, or database-only choice.
license: MIT
metadata:
  author: prisma
  version: "2.2.0"
---

# Prisma Postgres setup

Connect the intended database, then verify it from the application. Keep provisioning separate from ORM configuration so an existing database is reused.

## 1. Inspect the project

Check the user's requested ORM or driver, installed packages, database connection, and environment-loading files. Check secret presence without printing values.

- Honor explicit choices such as Drizzle, `pg`, or database-only setup.
- For query or schema work in an already configured app, use its version-matched ORM guidance; do not restart setup.

## 2. Reuse or obtain a database

| Situation                                    | Action                                                                                                           |
| -------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
| Existing connection or connected integration | Verify its project, database, and environment; reuse it.                                                         |
| v0, Vercel Marketplace, or a Vercel project  | Read [Marketplace setup](references/vercel-marketplace.md) and use the native integration flow.                  |
| No database yet and no provider named        | Offer `npx create-db@latest` for a working database now with no account (it is deleted after 24 hours unless claimed, and claiming needs a free Prisma account; read the create-db section in [provisioning](references/provisioning.md)), or a persistent database through [provisioning](references/provisioning.md). Ask which one when the request does not say. |
| Standalone persistent database               | Read [provisioning](references/provisioning.md); use an authenticated CLI, MCP tool, Console, or Management API. |
| Temporary development database requested     | Read the `create-db` section in [provisioning](references/provisioning.md), including expiry and claiming.       |

Resolve the workspace, project, and region before creation. If several resources fit, ask which one to use. If provisioning is blocked by permissions or quota, report the blocker; do not delete another resource or switch workspaces to get around it.

## 3. Connect the application

Use the connection appropriate to the chosen driver and runtime. Store it in the project's secret environment configuration, never source code or chat. Preserve unrelated entries, update the intended variable once, and ensure local secret files are ignored by Git.

Application processes and CLI commands may load different environment files. For example, a framework may load `.env.development.local` while a shell command does not. A variable missing from the shell does not mean the database is missing: load the intended file for that command without displaying credentials, and do not provision another database.

## 4. Configure the ORM and verify

For Prisma ORM setup, read [prisma-orm-setup/SKILL.md](https://github.com/prisma/skills/blob/main/prisma-orm-setup/SKILL.md) directly, or load the installed `prisma-orm-setup` skill when the host resolves sibling skills by name. It owns ORM version selection and configuration. If that handoff is unavailable, report it.

For an explicitly selected alternative, keep that ORM or driver and use its documented setup. For database-only setup, stop after verifying connectivity.

Run a read-only query against the intended database through the application's chosen ORM or driver. Report what was connected, the selected ORM/version, and the query result without secrets. If any step is blocked or untested, say so instead of claiming setup is complete.

For Studio, SDK integrations, or database operations beyond initial setup, read [operations](references/operations.md).

© prisma · MIT · prisma/skills

See also

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor