Tool reference
DB Schema Visualizer
alphaVisualize relational and document database schemas as an inspectable schema map. Paste SQL DDL, Prisma models, MongoDB JSON Schema, Mongoose snippets, or sample documents to review entities, fields, keys, references, indexes, and migration impact.
Quickstart
Use this when you want the shortest path from input to a useful result.
Paste SQL DDL, Prisma models, MongoDB JSON Schema, Mongoose schema snippets, or sample JSON documents into the editor.
Leave mode on Auto detect, or choose SQL DDL, Prisma schema, or NoSQL / Document manually.
For SQL, select Auto dialect or choose PostgreSQL, MySQL, SQL Server, Oracle, SQLite, or Generic SQL.
Use the table/collection filters, Index Advisor, Relationship Explorer, and details modal to inspect the schema.
Open the ER diagram for pan/zoom, search, focused relation viewing, SVG export, or PNG export.
Best for
Common situations where this tool fits naturally into the workflow.
- Paste a migration or CREATE TABLE script to quickly understand relational structure.
- Review Prisma model relationships before changing app persistence code.
- Inspect MongoDB-style collections, nested properties, ObjectId references, and inferred indexes.
- Compare an older schema against a new schema and classify migration impact.
- Export summaries, parsed JSON, and ER diagrams for tickets, docs, or planning.
Common tasks
Concrete ways this tool is typically used in day-to-day workflows.
Inspect SQL migrations
Paste CREATE TABLE statements from a migration file. The visualizer extracts columns, primary keys, unique fields, indexes, constraints, and inline or table-level foreign keys.
Map Prisma models
Paste one or more Prisma model blocks. Relations with fields/references metadata are displayed as links between models, and Prisma metadata such as enums, @map, @@map, @@schema, relation names, and @db native types are surfaced.
Inspect document collections
Paste MongoDB JSON Schema, Mongoose schema snippets, or sample JSON documents. The visualizer infers collections, nested property paths, document ids, likely ObjectId references, and reference indexes.
Review migration impact
Enable Diff, paste a previous schema and a new schema, then review added, removed, and changed tables, fields, and indexes with safe, caution, or breaking labels.
Create a shareable schema outline
Copy the summary or export Markdown, parsed JSON, SVG, or PNG output for docs, PRs, tickets, and planning notes.
Examples
Real inputs and outputs that show how the tool behaves.
SQL foreign-key map
A users/projects schema renders as two table cards and one owner relation.
SQL DDL
CREATE TABLE projects (id UUID PRIMARY KEY, owner_id UUID REFERENCES users(id));
Result
projects.owner_id -> users.id, with id marked as PK and owner_id marked as FK.
MongoDB document map
Sample documents are inferred into a collection with nested paths and likely references.
Sample document
{ "_id": "u_1", "email": "a@test.com", "orgId": "org_1", "profile": { "name": "Ava" } }Result
Document collection with _id as document id, profile.name as a nested property, and orgId marked as a likely reference.
Prisma relation map
Prisma models with @relation metadata are converted into relation rows.
Prisma
model Post { id String @id authorId String author User @relation(fields: [authorId], references: [id]) }Result
Post.authorId -> User.id with fields grouped under their model cards.
Features
What this tool includes and what each capability is for.
Relational + Document Input
Auto-detects SQL, Prisma, MongoDB-style JSON Schema, Mongoose schema snippets, and sample JSON documents.
Dialect-Aware Parsing
Supports SQL dialect selection for PostgreSQL, MySQL, SQL Server, Oracle, SQLite, and Generic SQL, plus document dialect selection for MongoDB, Firestore, and generic document schemas.
Entity Browser
Groups fields by table, model, or collection and labels primary keys, document ids, unique fields, optional fields, foreign keys, references, and nested document paths.
ER Diagram
Shows entities as searchable, pannable, zoomable diagram nodes with relation labels, inspector details, context actions, SVG export, and PNG export.
Index + Constraint Inspection
Highlights primary keys, unique constraints, composite indexes, foreign keys, reference fields, defaults, updated timestamps, and compact metadata panels.
Relationship Explorer
Shows inbound and outbound dependencies for the selected entity, including cascade delete behavior where available.
Schema Diff
Compares previous and new schema input, then classifies added, removed, and changed entities, fields, and indexes as safe, caution, or breaking.
Export Options
Copies a schema summary and exports Markdown, parsed JSON, SVG diagrams, and PNG diagrams.
Workflow
Follow this path to get from input to output quickly.
Open DB Schema Visualizer from the workbench.
Paste SQL DDL, Prisma models, MongoDB JSON Schema, Mongoose schema snippets, or sample JSON documents into the editor.
Choose Auto detect, SQL DDL, Prisma schema, or NoSQL / Document from the mode selector.
When using SQL or document mode, choose a dialect manually if Auto detect is not specific enough.
Review the generated entities, parser notes, indexes, constraints, advisor notes, references, and relationship explorer.
Open the ER diagram when you need a visual map, focused relation view, or image export.
Enable Diff when comparing a previous schema against a new schema.
Copy or export the generated summary when you need a portable schema outline.
Caveats and tips
Things to keep in mind before relying on the output in a larger workflow.
Caveats
- This is a client-side visualizer, not a full database parser. Complex vendor-specific DDL, procedural migration logic, or dynamic schema code may need cleanup before parsing.
- SQL dialect detection is heuristic. Select the dialect manually when a migration mixes vendor syntax or uses unusual types.
- Document mode infers shape from the supplied sample or schema. Sparse production data can contain fields not visible in a small sample.
- Mongoose parsing is lightweight and focused on common Schema definitions; highly dynamic JavaScript schema construction may not be fully detected.
- Prisma implicit many-to-many relations do not have fields/references metadata, so they are shown as fields rather than concrete foreign-key links.
- Composite keys and indexes are detected in common SQL and Prisma patterns, but relation summaries stay field-oriented.
Tips
- Use Auto detect for mixed daily work, then switch modes or dialects manually when a schema uses unusual syntax.
- Keep migrations focused when pasting large files; smaller schema chunks are easier to inspect.
- Use filters like No indexes, Cascade delete, Composite indexes, Nullable fields, JSON fields, or No relations to find risk areas quickly.
- Use the Relationship Explorer to see inbound and outbound dependencies before deleting or renaming an entity.
- Use the expanded details modal when a table or collection has many fields, indexes, or constraints.
- Copy the summary into Doc Builder when you need a lightweight schema reference inside project docs.