prisma-upgrade-v7

Migrates Prisma ORM projects from v6 to v7 across all breaking changes.

Updated Aug 19, 2026
One-click install
npx skills add https://github.com/nethangabrielb/tasks-app-practical-exam --skill prisma-upgrade-v7-nethangabrielb
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-upgrade-v7
Source: https://github.com/nethangabrielb/tasks-app-practical-exam/tree/main/packages/database/.agents/skills/prisma-upgrade-v7
Command: npx skills add https://github.com/nethangabrielb/tasks-app-practical-exam --skill prisma-upgrade-v7-nethangabrielb

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Upgrading from Prisma ORM v6 to v7 introduces breaking changes around the new prisma-client generator, mandatory driver adapters, prisma.config.ts, explicit environment loading, and new generated client entrypoints, and this Skill guides the entire migration. ## Core Features & Use Cases - Step-by-Step Migration: Walks through package updates, ESM or CommonJS module format selection, TypeScript configuration, schema generator changes, and client instantiation. - Driver Adapter Setup: Covers required adapter installation and configuration for PostgreSQL, MySQL, SQLite, SQL Server, Neon, PlanetScale, and Prisma Postgres. - Removed Feature Replacements: Shows how to replace $use middleware with Client Extensions, Prisma.validator with TypeScript satisfies, and removed CLI flags with prisma.config.ts options. - Use Case: A NestJS project on Prisma 6 fails after upgrading packages with "Cannot find module" and missing adapter errors; follow the schema-changes and driver-adapters references to update the generator block, install @prisma/adapter-pg, and regenerate the client. ## Quick Start Ask the assistant to upgrade my project from Prisma 6 to Prisma 7 and fix the resulting generator, adapter, and import errors.

Frequently Asked Questions about prisma-upgrade-v7

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I upgrade Prisma from v6 to v7?▼

Update @prisma/client and prisma to version 7, switch the generator provider to prisma-client with an explicit output path, create prisma.config.ts, install a driver adapter such as @prisma/adapter-pg, update client imports and instantiation, then run prisma generate.

What is the prisma-client generator in Prisma 7?▼

prisma-client is the default generator in Prisma 7, replacing prisma-client-js for current projects. It requires an explicit output path, generates client, browser, models, and enums entrypoints, and supports ESM by default with moduleFormat = "cjs" as an option.

Does Prisma 7 require driver adapters?▼

Yes, Prisma 7 requires driver adapters for SQL providers because the client no longer ships a native query engine. Install the adapter matching your database, such as @prisma/adapter-pg for PostgreSQL, and pass it to the PrismaClient constructor.

Can I use Prisma 7 with MongoDB?▼

No, Prisma 7 has no MongoDB connector and no MongoDB driver adapter. MongoDB projects should stay on the latest Prisma 6.x release or migrate to Prisma Next instead of following the standard v7 SQL migration path.

Why does Prisma 7 not load my .env file automatically?▼

Prisma 7 removed automatic environment variable loading, so you must install dotenv and add import 'dotenv/config' as the first line of prisma.config.ts. Bun users are exempt because Bun loads .env files automatically.

How do I replace Prisma.validator in Prisma 7?▼

The prisma-client generator no longer exposes Prisma.validator, so use TypeScript's satisfies operator instead. Define your select or include object as a plain literal annotated with satisfies Prisma.UserSelect or the equivalent model type.