Paste CREATE TABLE DDL and get an interactive entity-relationship diagram in your browser. Parsing and rendering stay on your machine with no upload or account.
Overview
SQL to ER Diagram turns SQL schema definitions into an interactive entity-relationship diagram. You paste CREATE TABLE statements or related schema text, and the tool builds a canvas view of tables, columns, keys, and foreign-key relationships.
Processing runs entirely in the browser, so schema text is not sent to a backend server. The app supports multiple SQL dialects for DDL parsing, including PostgreSQL, MySQL, SQLite, SQL Server, and Snowflake, and can also ingest Prisma, DBML, Mermaid, PlantUML, and several ORM model formats. You can drag tables, zoom and pan, auto-arrange layout, edit names and types on the canvas with changes reflected back in the SQL, and add notes or group boxes on the diagram.
You can keep several named diagrams in the browser, use version snapshots, compare schemas and generate migration SQL, export PNG or SVG, save or open JSON project files, and share diagrams via a URL that encodes the project in the fragment. A service worker can cache the app for offline use after the first visit. Static build output can be hosted on generic static hosting if you want your own copy of the site.
The authors position it as a free alternative to tools they describe as paywalled, slow, or limited, emphasizing a single static page that remains responsive on large schemas with hundreds of tables.
Key features
- CREATE TABLE and ALTER TABLE DDL parsing
- Interactive canvas ERD with zoom and pan
- Two-way SQL and diagram editing
- Auto-arrange layout in a Web Worker
- Import Prisma, DBML, Mermaid, and ORM models
- PNG, SVG, and project file export
- Share links with diagram encoded in the URL
- Offline use via service worker caching
Use cases
- Documenting an existing database schema visually
- Exploring foreign keys on large SQL dumps
- Sharing an ERD without sending SQL to a server
- Comparing schema versions and drafting migrations
- Converting or exporting schema between SQL dialects
Open-source alternative to