Generate an ER Diagram from SQLite
Turn tables and foreign keys into a map you can read. Open a SQLite database or run your CREATE TABLE statements, then explore the relationships.
CREATE TABLE customers (
id INTEGER PRIMARY KEY,
name TEXT NOT NULL
);
CREATE TABLE orders (
id INTEGER PRIMARY KEY,
customer_id INTEGER
REFERENCES customers(id),
total REAL
);Bring a schema
Open an unencrypted SQLite database, or create a workspace and run SQLite-compatible CREATE TABLE statements.
Choose what to see
Open the ER diagram tab. Select a subset of tables to focus the diagram, and zoom to inspect the details.
Take the map with you
Download the diagram as an SVG. The Schema tab also shows column types, declared keys, indexes, and CREATE statements.
Before you dive in.
Everything runs locally. Here is what to expect.
Understanding foreign keysDoes this infer relationships from column names?
Diagram lines come from declared SQLite foreign keys. Naming-based suggestions are available for review, but matching names such as customer_id do not prove a relationship. CSV imports do not create foreign keys automatically.
Can I use PostgreSQL or MySQL SQL?
The current generator accepts SQLite-compatible SQL only. Convert dialect-specific syntax before running the script. SQL scripts open for review rather than executing automatically.
Can I drag tables or edit relationships?
Yes. Drag tables, retain their layout locally, inspect connections and review relationship migrations before applying them. Table selection, zoom, fit and SVG export are also available.
What do the relationship symbols mean?
Lines identify declared references. The diagram does not prove whether data satisfies those references or infer exact business cardinality. Use the schema details for nullability and uniqueness constraints.
Try a concrete task
Open a sample dataset and inspect its tables and relationships. Use the SQL reference for examples with expected output, or follow a guided practice path. To investigate query access patterns, select one SELECT and use Explain in the workspace.