Paste SQL DDL to inspect the detected database structure. Review the diagram and reuse its Mermaid source in your documentation.
Runs locally in your browserPaste one or more CREATE TABLE statements and the page renders the tables, their columns and the foreign keys between them: Mermaid erDiagram source in the output pane, a small SVG preview underneath that the page draws itself.
MySQL backticks, PostgreSQL double quotes, SQL Server square brackets, IF NOT EXISTS and schema.table prefixes are all read, and -- or /* */ comments are ignored. Nothing is uploaded and no database connection is opened.
Every table becomes a card listing its columns in declaration order. Primary key columns carry PK, columns used by a foreign key carry FK, and a composite key marks all of its columns. A key declared twice - inline as REFERENCES and again as a table-level FOREIGN KEY - is counted once and drawn as a single edge.
An edge runs from the referenced table to the table that declares the key, and its label names the key column, so users ||--o{ projects : "owner_id" reads as: one user row owns many project rows. Connectors leave and enter a card at its edge and a self-reference loops around the right side of its own card, so no line crosses a table body.
A name alone does not identify a table. When a.users and b.users are both in the paste, the Mermaid source keeps them apart as users and users_2 while the cards keep the qualified labels. A foreign key whose target table is not part of the paste keeps its edge and is drawn as a dashed placeholder instead of disappearing.
The status line reports what the diagram does not contain: how many DDL lines could not be read, and how many relationships point outside the pasted text. A paste with no CREATE TABLE at all clears both panes and says why, rather than leaving the previous diagram on screen.
This is a diagram builder, not a database client: it does not connect to a server, execute SQL, read a running schema or produce migrations. It renders the text you paste, and the Mermaid source is meant for documentation and review.
The whole tool runs in the browser; once the page has loaded it requests nothing further and it keeps working offline. Copy and Download stay inactive until a diagram has been rendered, so an empty clipboard or a zero-byte file cannot be mistaken for a result. Diagram size is limited only by the memory of the tab.