# One schema. Every query type-safe. (/orm)

> Prisma ORM | Type-Safe ORM for TypeScript and Node.js. For the complete Prisma website index, see [llms.txt](https://www.prisma.io/llms.txt). A Markdown version of any listed page is available at its `.md` URL — this one is `/orm.md`.

Prisma ORM is a type-safe ORM for TypeScript and Node.js. Model your data, run migrations, and query your database, with access your agent can't get wrong.

Define your data model once, and Prisma ORM generates a typed client where every query, migration and type is checked against it.

- [View on GitHub](https://github.com/prisma/orm)
- [Read the docs](/docs)

Works with Postgres, MySQL, SQLite, MongoDB and more.

- Autocomplete over your own models, and mistakes caught before they ship
- Migrations that refuse to run when they would destroy data
- Free, open source, trusted by 500K+ developers

### Prisma ORM at a glance

- **Schema** — One file your whole stack reads: models, field types and relations declared in one place.
- **Client** — A typed client generated from that schema, so a wrong field name fails in your editor, not in production.
- **Migrations** — Prisma refuses a migration that would destroy data, and tells you what it would have dropped.
- **Any database** — The same schema and the same generated client over Postgres, MySQL, SQLite, MongoDB and more.

## Without a typed schema, your data layer is guesswork

When your data model lives across loosely-typed files and hand-written SQL, mismatches surface at runtime instead of in your editor, and nothing can check a change against the schema before it runs. That is true when you write the change, and it is far more dangerous when an agent does.

Prisma ORM exists to change that.

- One schema your whole stack reads
- Every query checked before it ships
- Migrations that refuse to destroy data
- The same client over any database

## A schema your whole stack reads

Your data model is written once and read everywhere: by you, by your agent, and by every other Prisma product.

- **Declarative schema** — Define your data model in one dense, machine-readable file. Easy for you to scan, easy for your agent to parse and edit reliably.
- **Type-safe client** — A fully typed query client generated from your schema. Autocomplete everywhere, and mistakes caught before they ship instead of in production.
- **Built for agents, not just humans** — Errors carry stable codes, structured details, and remediation hints. Your agent reads what went wrong and fixes it, through a clean CLI and Management API.

## Migrations your agent can run without breaking production

Migrations are where agentic development gets dangerous — it's the moment an agent can alter or delete data irrecoverably. Prisma makes them safe to delegate.

Change your models and Prisma generates the migration in TypeScript you can read and edit, not SQL you have to decipher. Every step is verified before and after it runs, and the result must match your schema to be applied.

Because life is rarely a straight line, migrations are tracked as a graph, like git: roll back, branch, and named refs point at multiple environments. Your agent drives the whole lifecycle through a predictable CLI — plan, apply, inspect — without ever hand-writing SQL, and never "drop the database and start over."

## Fast feedback makes your agent faster, and more reliable

Prisma ORM is built to give your agent feedback at every step so it can iterate to success without human intervention. The more feedback it gets from its environment, and the sooner it gets it, the fewer attempts it takes to reach correct, verified code.

- **Expert from the first prompt** — Setting up a project installs the Prisma skills for your coding agent, so it knows the right patterns before it writes a line.
- **The type system catches mistakes instantly** — Every query is checked against your schema before it ships. Wrong column, wrong type, missing relation — your agent finds out instantly, not in production.
- **Errors built to be read by agents** — When something fails at runtime, the error carries a stable code, structured details, and remediation hints. Your agent reads what went wrong and fixes it.
- **Guardrails before anything touches your data** — Queries and migrations are verified against your schema before execution. A drifted schema or an invalid plan is rejected up front, with an error that says why.

## Built to work with the rest of Prisma

The schema you write for the ORM is the same schema your database and hosting read. Adopt the ORM and you've already laid the foundation for the rest of the stack, with no rework when you're ready to expand.

**Best together. Swappable when needed.**

## Trusted by 500K+ TypeScript developers

- "Prisma makes database management incredibly easy. Prisma's built-in type safety helps us avoid mistakes that happen with manual setups." — Ron Cohen, Co-founder & CTO, Bucket
- "We are able to take advantage of caching to speed up queries and reduce latency, making them lightning fast." — Blake Carroll, CTO, Solin
- "Prisma has a low learning curve. Productivity becomes higher because it gets combined with end-to-end type-safety using TypeScript." — Ricardo Almeida, Software Engineer, Grover
- "Prisma's approach to type-safe ORM is next-level. It provides full type-safety without any codegen or messy types and interfaces to write and maintain." — Pieter Venter, Sr. Software Engineer, Invisible
- "The combination of Prisma, TypeScript and our pretty thorough coverage with integration tests gives us the confidence to refactor critical parts of our code." — Thibaut Nguyen, CTO, Poppy
- "This is the fastest I've ever developed in my life, by far. The tooling has dramatically cut down on the amount of time I've had to spend." — Sean Emmer, CTO & Co-Founder, Pearly Plan
- "We chose Prisma because it provides us with type safety directly from the database. It has helped us tremendously to catch possible errors early on." — Omar López, Sr. Software Engineer, Cal.com
- "We've proudly built the core of our APIs on top of Prisma, and we are very happy that we did. It doesn't make us jump through unnecessary hoops to get normal work done and generally just works." — James Fox, Co-Founder, Gamma
- "Prisma is the best ORM I have ever used, I never want to use anything else again. The excellent developer experience with its incredible TypeScript support sold me at first." — Max Stoiber, Founder, Stellate
- "Prisma is a professional enterprise-ready tool that is easy to start using, ramp up and scale. It is the type of tool developed for the software engineers of today." — Matt Matheson, Co-Founder, Trunk
- "Prisma has been an absolute game changer for Memberstack. It has helped us move faster while also improving product stability." — Tyler Bell, Co-founder, Memberstack
- "I chose Prisma because of its clean API, nice developer experience and type safety. It helped me ship v1 of Instatus really fast." — Ali Salah, Founder, Instatus

## Start with the ORM. Keep everything else within reach.

Prisma ORM is part of a TypeScript stack built to work together end-to-end. Adopt the ORM today and the rest of the platform clicks in when you're ready, with no schema rework.

- Free and open source, your schema is yours forever
- Add a database and hosting when you're ready, with no rework
- The TypeScript stack 500K+ developers already trust

- [View on GitHub](https://github.com/prisma/orm)
- [Read the docs](/docs)
