Getting Started
Learn how to set up and use Prisma Studio to manage your database
Installation
Prisma Studio comes bundled with the Prisma CLI. To get started, make sure you have Node.js installed, then install the Prisma CLI:
npm install -g prismaLaunching Studio
With a Prisma Project
If you have an existing Prisma project, navigate to your project directory and run:
npx prisma studioThis will start the Studio server and open it in your default browser at http://localhost:5555.
Without a Prisma Project
You can also use Studio with any database by providing a connection string:
npx prisma studio --url="postgresql://user:password@localhost:5432/yourdb"Connecting to Your Database
-
Using environment variables: Create a
.envfile in your project root with your database URL:DATABASE_URL="postgresql://user:password@localhost:5432/yourdb"Then run:
npx prisma studio -
Using command line:
npx prisma studio --url="your-database-connection-string"
Basic Usage
Browsing Data
- The left sidebar lists all your database tables
- Click on a table to view its data
- Use the search bar to quickly find tables or columns
Editing Data
- Edit cells: Double-click any cell to edit its value
- Add records: Click the "+" button to add a new record
- Delete records: Select records using checkboxes and click the trash icon
Filtering and Sorting
- Click the filter icon to add filters
- Click on column headers to sort the table
- Use the search box to filter records by any field
Common Tasks
Viewing Table Relationships
- Related tables are shown as expandable rows
- Click the "+" icon to view related records
Exporting Data
- Use the export button to download data as CSV or JSON
- Select specific columns to include in the export
Next Steps
- Learn how to embed Studio in your application
- Discover VS Code integration features