CLI tool
prisma/studio avatar
prisma/studio

Prisma Studio: the database editor that has quietly become an embeddable package

🎙️ The easiest way to explore and manipulate your data in all of your Prisma projects.

2,230 stars84 forksTypeScriptNOASSERTION

At a glance

What is it?
Most people meet Prisma Studio as one CLI command. The repository tells a different story: the GUI is now published as a library that other products embed, with the AI plumbing pushed entirely to the host.
Who is it for?
The interesting thing about this repository is what it is not: it is not where you go to use Prisma Studio. The README says so directly, that you do not need this repository to run `npx prisma studio`, and that the package published from here is consumed by other Prisma surfaces rather than used standalone.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository received new commits within the last day.
What is it written in?
Mainly TypeScript, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on October 7, 2026, and from our analysis. They are not legal advice.

Editorial analysis

The command most people know, and why the repo is not for them

The README's second paragraph is the most useful thing in it. It says Prisma Studio is the visual editor for exploring and editing your database, and then immediately tells you that if you already use Prisma ORM you do not need this repository:

sh
npx prisma studio

That one line is the entire installation story for a user. It also frames the repository correctly: this is the OSS home of `@prisma/studio-core`, the package that powers Studio inside Prisma CLI and Prisma Console, not an application you build or run.

A second line covers the hosted variant. Prisma Postgres projects can use Studio inside Prisma Console, which adds AI-assisted workflows such as SQL generation and AI-powered filters. So there are three surfaces, all sharing this package: the CLI command, the hosted Console, and whatever a third party embeds.

The distinction matters when you are reading the repository, because the code here is designed for consumption rather than for a demo. The local development path is explicitly a demo:

sh
pnpm install
pnpm demo:ppg

Architecture notes are kept in a separate `Architecture/` directory and release procedure in `RELEASE.md`, which is how a package intended to be embedded by several internal products is usually organised.

One required prop, one optional prop, and nothing in between

The embedding section is the heart of the README and its design is unusually disciplined. There is a required `adapter` and an optional `llm`. There is no third option.

The `llm` prop is described as the single supported AI transport hook for all Studio AI features. The features it covers are AI filtering, AI SQL generation, AI visualization and Query Insights recommendations. When `llm` is omitted, Studio hides all four entirely rather than showing controls that cannot work, and the README states plainly that there are no per-feature AI integration props to wire separately.

The wire format is small. Studio sends a fully constructed prompt plus a task label, and the host returns either a success with text or a failure with a code and a message. The task label is a union of four values:

ts
task:
  | "table-filter"
  | "sql-generation"
  | "sql-visualization"
  | "query-insights";

What the host is expected to do is deliberately minimal. Forward the prepared request to a model, return the typed result. Studio builds the prompt, validates it, and on the other side converts the answer into the normal filter, SQL and visualization surfaces.

The `queryInsights` flag is the other half of the contract and follows the same philosophy of fail-closed behaviour. Pass it only when your backend implements the `query-insights` procedure, otherwise omit it so Studio hides the `Queries` view. An explicit instruction to leave a capability off unless the backing implementation exists is rarer than it should be, and it is what keeps the embedded surface from looking broken.

Where the AI responsibility actually sits

The paragraph that clarifies the split best is the one on correction. Studio handles prompt construction, type-aware validation, pre-display SQL validation for AI-generated SQL, correction retries, database-error correction, and conversion into the ordinary surfaces.

Three of those deserve emphasis because they are the difference between a demo and something usable. SQL is validated before you see it, so a malformed query does not reach your database through the AI path. If a generated query still fails after you run it manually, Studio sends both the failing SQL and the database's error back through the same transport so the model can propose a correction without auto-executing it. And `output-limit-exceeded` is treated as a first-class retry signal for the SQL generation and visualization loops rather than as an error to surface.

The last detail closes the loop. When a SQL linter is available, Studio validates generated SQL before showing it and feeds lint diagnostics back through the same `sql-generation` transport when a correction is needed. One transport, used for the first attempt, for lint feedback and for error recovery.

The README's summary of this is the sentence to remember: all prompting and retry behaviour live in Studio itself, so host implementations should stay transport-only. That is a real division of labour. A host that constructs its own prompts will drift from Studio's expectations, and the type definitions are what keep it honest.

Visualization follows the same path. The host supplies no chart components, no options object and no callbacks. Studio builds the prompt from the executed SQL, the database engine and the full result rows, and validates the reply as a small chart config before rendering, accepting bar, horizontal-bar, line, pie and doughnut.

Metadata that belongs to a different project

Two fields in this repository's metadata do not describe Prisma Studio, and a reader who trusts the metadata over the README will be misled.

The first is the license, reported as NOASSERTION while the tree contains both a `LICENSE` and a `NOTICE` file. The second is the topics list, which reads `loggy-core` and `loggy-strike-team`. Nothing in the README, the package name or the commit history connects this repository to anything called Loggy. Those look like leftover fields from a template or an internal codename.

Neither is harmful on its own. GitHub reports NOASSERTION when a repository's license is not one it recognises as standard, which can happen with a modified or composite license file, and topics are free text. But together they are a reminder that repository metadata is a claim rather than evidence, and that the README is the more reliable source about what a project is.

The rest of the metadata is consistent with what the README describes. TypeScript, 2225 stars, 84 forks and 39 open issues, last pushed 2026-09-22, not archived. The fork count is low relative to the star count, which fits a package consumed as a dependency rather than cloned for reading.

The tree also shows the shape of an AI-assisted repository workflow. Alongside the expected `ui/`, `lib/`, `data/`, `demo/` and `docs/` directories there are `AGENTS.md`, an `.agents/` directory, a `skills-lock.json` and a `checkpoint/` directory. `FEATURES.md`, `PRODUCT.md` and `RELEASE.md` sit at the root as separate documents rather than one wiki.

The export map is the actual public API

package.json is worth reading for this package because the `exports` field defines what consumers can reach, and it is more granular than a single entry point usually is.

There is a `./data` entry, then database-specific ones: `./data/mysql-core`, `./data/mysql2` and `./data/node-sqlite`. There is `./data/bff`, which is the backend-for-frontend client the embedding example constructs. Each entry publishes both an ESM build and a CommonJS build, with matching `.d.ts` and `.d.cts` type declarations, which is why the `exports` blocks are nested under `import` and `require` keys rather than being a single string.

The pairing of `mysql-core` and `mysql2` is the interesting part. One is the core logic and the other is presumably the driver binding, which separates the code that builds queries from the code that opens a connection. Postgres follows the same pattern in the README example, where `createPostgresAdapter` takes an executor rather than constructing its own connection.

The package is ESM-first with `type: module`, declares `sideEffects: false`, and was at version 0.33.0 when this material was gathered. Being pre-1.0 is the honest signal here: the subpath exports are likely to move, and a host pinning a specific version is doing the right thing. The description field is generic, Modular Prisma Studio components, which is less informative than the README it sits next to.

The local demo runs against real databases, not mocks

The docker-compose file in the repository shows what the test and demo setup actually exercises, and it is more extensive than a single database.

The first service is MySQL 8.0.40 with a set of InnoDB settings that are plainly there to make a containerised database fast rather than durable. Durability is traded away deliberately and the reason is written in the file: `--sync_binlog=0`, `--innodb_doublewrite=OFF`, `--innodb-flush-log-at-trx-commit=0` and `--innodb-flush-method=nosync`. The inline comment notes that nosync only applies on unix and needs editing to start locally elsewhere. Crashing the database is fine for a demo and destroying your data is not, so this is a reasonable trade for a test harness and a bad one to copy into anything real.

The second service is Vitess, running `vitess/vttestserver:mysql80` with a platform pinned to linux/amd64 and ports mapped from 15303. That is a MySQL-compatible proxy layer in the harness, which suggests the adapter is tested against something that behaves like MySQL without being MySQL.

The `.env.example` file contains two lines and the first is a switch. `STUDIO_DEMO_AI_ENABLED` can be set to false to hide the demo's AI interface even when an Anthropic key is present, and the key itself is `ANTHROPIC_API_KEY`. So the AI features are demonstrated against a real provider, with a flag to turn them off.

The releases show the pace. v0.33.0 fixed duplicate startup introspection requests by not cancelling and repeating them when Studio first mounts. v0.32.0, the day before, added the migration view described below. Two releases on consecutive days in July 2026, both small and both aimed at correctness.

What the migration view reads out of the database

The v0.32.0 notes describe the most substantial recent feature and it is more interesting than it first appears, because it does not need a migration file to do it.

The condition is a Prisma Next migration ledger at `prisma_contract.ledger` with at least one applied migration. When the connected database carries one, Studio shows a Migrations navigation item with a newest-first timeline of every applied migration: name, apply time, operation count, destructive-change markers, and compact plus, minus and tilde chips summarising what changed.

The rendering is a visual diff canvas built from contract snapshots the ledger records alongside itself. Models that were added, removed or changed appear as colour-coded cards with per-field before and after detail, covering type, nullability, defaults and primary keys. Enums and relation edges get their own treatment. An All models toggle expands to the migration's full schema.

What makes this a database feature rather than a tooling feature is the source of truth. The history is read from a ledger already present in the database, not reconstructed by replaying migration scripts. For a team that has databases spread across environments, that means the visual history of a schema is available wherever the database is, including a replica restored from backup.

The notes also carry an honest limitation, noting that databases whose ledger predates a certain point are handled differently. Feature work that states its own boundary condition is easier to evaluate than feature work that does not.

Editorial conclusion

The interesting thing about this repository is what it is not: it is not where you go to use Prisma Studio. The README says so directly, that you do not need this repository to run `npx prisma studio`, and that the package published from here is consumed by other Prisma surfaces rather than used standalone. What that leaves is the package contract, and it is a well-specified one. A host supplies an adapter and optionally a single `llm` transport, and Studio handles prompt construction, SQL validation before display, correction retries and turning a failure back into a repair request. Omit the `llm` prop and every AI affordance disappears rather than half-working. If you are embedding, that adapter boundary is the design decision to make first, and the `Architecture/` notes are the place to read next.

Frequently asked questions

How do I start Prisma Studio?

Run npx prisma studio in a project that already uses Prisma ORM. The README states you do not need the studio repository itself to use that command.

Can I embed Prisma Studio in my own product?

Yes, through the @prisma/studio-core package. You pass a required adapter and an optional llm transport into the Studio component, and the package is published to npm for use by other surfaces.

What happens if I do not pass the llm prop?

Studio hides AI filtering, AI SQL generation, AI visualization and Query Insights recommendation affordances entirely. There are no per-feature AI props, so the hook is all or nothing.

What does the queryInsights prop do?

It enables the Queries view, and should only be passed when your backend implements the query-insights procedure. If omitted, Studio hides the view rather than offering a control that cannot work.

Official sources

  1. Issues
  2. prisma/studio on GitHub
  3. Project website
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/prisma-studio.svg)](https://hysenlabs.com/projects/prisma-studio)