🌐
Prisma
prisma.io › home › overview of prisma schema › overview of prisma schema › overview of prisma schema
Prisma schema | Prisma Documentation
Generators: Specifies what clients ... schema.prisma (or multiple files with .prisma file extension) that is stored in a defined but customizable location....
🌐
Wasp
wasp.sh › prisma schema file
Prisma Schema File | Wasp
With Prisma, you define your application's data model in a schema.prisma file.
🌐
Prisma
prisma.io › blog › organize-your-prisma-schema-with-multi-file-support
Organize Your Prisma Schema into Multiple Files
June 4, 2024 - Prisma ORM lets you organize your Prisma Schema into multiple files. You split your models across as many .prisma files as you like, relations work across files without any imports, and Prisma combines everything when you run prisma generate or a migration command.
🌐
Prisma
prisma.io › home › config api › config api › config api
Reference documentation for the prisma config file | Prisma Documentation
In that case, your migrations directory must be located next to the .prisma file that defines the datasource block. For example, assuming schema.prisma defines the datasource, here's how how need to place the migrations folder:
🌐
Visual Studio Marketplace
marketplace.visualstudio.com › items
Prisma - Visual Studio Marketplace
May 19, 2026 - Extension for Visual Studio Code - Adds syntax highlighting, formatting, auto-completion, jump-to-definition and linting for .prisma files.
🌐
GitHub
github.com › prisma › prisma › discussions › 19113
What is the format of Prisma file (.prisma)? · prisma/prisma · Discussion #19113
Prisma has its own format called the Prisma Schema Language (PSL) for defining database models and configurations. The Prisma schema is a .prisma file that uses the PSL to define your application's data model and other configurations.
Author   prisma
🌐
YouTube
youtube.com › watch
Using Multiple Prisma Schema Files - YouTube
Starting at Prisma 5.15, we can now split our schemas up into multiple files. This is useful for scenarios where different team members are working on differ...
Published   January 8, 2025
Find elsewhere
🌐
Medium
medium.com › @Christopher_Tseng › meet-prisma-your-friendly-guide-to-easier-database-work-648a6e1c9dc0
Meet Prisma: Your Friendly Guide to Easier Database Work | by Christopher Tseng | Medium
May 30, 2025 - What does this do? It creates a new little folder called prisma in your project. Inside, you'll find a key file: schema.prisma. This is where you'll describe what your data looks like.
🌐
DevGenius
blog.devgenius.io › splitting-prisma-schema-into-multiple-files-a-simple-guide-0e28da7c5cd7
Splitting Prisma Schema into Multiple Files: A Simple Guide | by Tanzim Hossain | Dev Genius
October 10, 2025 - Hey buddy! Today, I want to share a solution I found for a common problem with Prisma. By default, Prisma uses just one file called schema.prisma to store all your database models. This can get messy when your project grows.
Top answer
1 of 6
12

At this point in time Prisma doesn't support file segmentation. I can recommend 3 solutions though.

Option 1: Prismix

Prismix utilizes models and enums to create relations across files for your Prisma schema via a prismix configuration file.

{
  "mixers": [
    {
        "input": [
            "base.prisma",
            "./modules/auth/auth.prisma", 
            "./modules/posts/posts.prisma",
        ],
        "output": "prisma/schema.prisma"
    }
  ]
}

Placing this inside of a prismix.config.json file which will define how you'd like to merge your Prisma segmentations.

Option 2: Schemix

Schemix Utilizes Typescript configurations to handle schema segmenting.

For example:

// _schema.ts
import { createSchema } from "schemix";

export const PrismaSchema = createSchema({
  datasource: {
    provider: "postgresql",
    url: {
      env: "DATABASE_URL"
    },
  },
  generator: {
    provider: "prisma-client-js",
  },
});

export const UserModel = PrismaSchema.createModel("User");

import "./models/User.model";

PrismaSchema.export("./", "schema");

Inside of User.model

// models/User.model.ts

import { UserModel, PostModel, PostTypeEnum } from "../_schema";

UserModel
  .string("id", { id: true, default: { uuid: true } })
  .int("registrantNumber", { default: { autoincrement: true } })
  .boolean("isBanned", { default: false })
  .relation("posts", PostModel, { list: true })
  .raw('@@map("service_user")');

This will then generate your prisma/schema.prisma containing your full schema. I used only one database as an example (taken from documentation) but you should get the point.

Option 3: Cat -> Generate

Segmenting your schema into chunk part filenames and run:

cat *.part.prisma > schema.prisma
yarn prisma generate

Most of these if not all of them are referenced here in the currently Open issue regarding support for Prisma schema file segmentation https://github.com/prisma/prisma/issues/2377

2 of 6
9

Starting from Prisma 5.15 this can be done without any external tools, please see the following blog post.

Sample project

Briefly, all you need to do is:

  1. In your schema.prisma file - make sure you have this feature enabled as follows:

    generator client {
      provider        = "prisma-client-js"
      previewFeatures = ["prismaSchemaFolder"]
    }
    
  2. Create a dir named schema under your prisma directory

  3. Move your schema.prisma file into that directory. You should now be able to create more .prisma files in there and define your models. It all gets hooked up automatically, no need to import anything.

🌐
Open
start.open.gov.sg › concepts › prisma
Prisma - Starter Kit - Open Government Products
Prisma is an ORM for TypeScript, that allows you to define your database schema and models in a schema.prisma file, and then generate a type-safe client that can be used to interact with your database from your backend.
🌐
DEV Community
dev.to › 0xtanzim › splitting-prisma-schema-into-multiple-files-a-simple-guide-ni1
Splitting Prisma Schema into Multiple Files: A Simple Guide - DEV Community
March 3, 2025 - Hey buddy! Today, I want to share a solution I found for a common problem with Prisma. By default, Prisma uses just one file called schema.prisma to store all your database models. This can get messy when your project grows.
🌐
YouTube
youtube.com › watch
Using Multiple Prisma Schema Files in Prisma 7 - YouTube
Prisma 7 is here! This is how you can use multiple schema files in your codebase.To learn more about everything included in this major release of *Prisma ORM...
Published   January 28, 2026
🌐
Quickstart
quickstart.md › quickstarts › prisma
Prisma Quickstart - quickstart.md
February 3, 2026 - ✔ Your Prisma schema was created at prisma/schema.prisma You can now open it in your favorite editor. ... Set the DATABASE_URL in the .env file to point to your existing database.
🌐
Prisma
prisma.io › home › prisma cli reference › prisma cli reference › prisma cli reference
Prisma CLI reference | Prisma Documentation
Be sure to back up your current schema.prisma file (or commit your current state to version control to be able to revert any changes) before running db pull if it contains important modifications. Introspection with the db pull command on the MongoDB connector samples the data instead of reading a schema. Before using the db pull command, you must configure your database connection in your prisma.config.ts file.
🌐
GitHub
github.com › prisma › prisma › discussions › 24413
Preview feature feedback: `prismaSchemaFolder`, Multi-file Prisma Schema · prisma/prisma · Discussion #24413
I would like to use prisma in a monorepo that governs multiple applications. Many of the models will be shared across each application. It would be helpful to be able to specify a list of directories containing models that will be included for each application. Example of possible directory structure and configuration in app-specific schema file:
Author   prisma