Turn DBML into an ERD diagram
Start by editing the sample without signing up. Create a free workspace with Google or GitHub to manage your own documents or save to the cloud.
1. Prepare JSON or DBML
Free supports JSON and DBML import and export. In Import, select or paste a Schema Studio JSON or supported DBML file.
No file yet? Start with this example
Copy the example below into Editor → Import → DBML, then choose Validate DBML. It describes two related tables: customers and orders.
Table customers {
id integer [pk]
name varchar(100) [not null]
}
Table orders {
id integer [pk]
customer_id integer [not null]
total decimal(12,2) [not null]
}
Ref: orders.customer_id > customers.idStart with this example →2. Select your tables
Validate the schema and choose your tables. Up to 100 tables and 2MiB of input are supported; unsupported definitions are warned about and skipped.
3. Explore and keep your work
Edit relationships, display names and descriptions, then back up the full document as JSON. DBML exports supported schema structure. PNG export is also free. Basic and Pro, including SQL, SVG and dictionary exports, are currently disabled.
Edit with DBML code
Choose DBML code in the editor toolbar, edit the source, then Validate & preview → Apply code. Errors keep the current diagram intact, and one undo restores an applied edit. TableGroup names, colors, membership and one-to-one Ref are supported. A missing unique key on a one-to-one FK is added to preserve its meaning.
Comments and unsupported definitions such as Enum, checks and extensions remain only in the browser draft and Save source file. Code drafts are not included in cloud or JSON backups. The diagram applies supported structure; retain both the source and JSON. Code renames are treated as removal and addition; matching table and column names keep their IDs and layout.
Storage and backups
Edits are saved automatically in this browser. After signing in, save through the Cloud menu or enable cloud autosave for a linked document. On Free, changed schemas, descriptions and layouts are saved at one-minute intervals. Cloud autosave turns off when you leave the editor. Manual saves are immediate.
Browser copies remain after sign-out. Clearing site data removes them, and they are not available in another browser, so export a JSON backup for important work. On a shared computer, confirm your JSON backup or cloud save, then sign out and clear site data.
Supported scope and planned features
Free import supports Schema Studio JSON and a subset of DBML Table, Ref and TableGroup definitions. Review warnings and compare the result with your original schema. Use DBML to transfer supported structure and JSON to preserve the full document, including layout and descriptions. Supported PostgreSQL/MySQL DDL imports, the PostgreSQL metadata query and PNG export are also free. MySQL input is converted to the PostgreSQL document model; full MySQL syntax is not supported. SQL, SVG and dictionary exports are coming soon. Real-time collaboration is not available yet.
Start with the demo →Tell us where you got stuck
Tell us what you were trying to do and the error message you saw. Do not send database credentials, records or confidential schemas. A small example with fictional tables can help us reproduce the issue.
Send feedback or ask for help →