SQLiteFreeNo Sign-Up

Free SQLite Database Diagram Tool

Paste your SQLite CREATE TABLE statements or upload a .sql schema file to generate an interactive ER diagram. Perfect for mobile apps, embedded databases, and lightweight projects using SQLite.

What SQLite syntax is supported?

GraphMyDB handles all common SQLite DDL patterns, including features that are unique to SQLite:

AUTOINCREMENT

SQLite-style INTEGER PRIMARY KEY AUTOINCREMENT is detected and displayed as a constraint badge.

IF NOT EXISTS

CREATE TABLE IF NOT EXISTS is fully supported without affecting parsing.

Bracket-quoted identifiers

SQLite [bracketed] identifiers are parsed correctly alongside regular and double-quoted names.

Type affinity

SQLite's flexible type system (TEXT, INTEGER, REAL, BLOB, NUMERIC) is preserved in the diagram.

FOREIGN KEY

Inline REFERENCES and table-level FOREIGN KEY constraints create visual edges between tables.

DEFAULT values

DEFAULT CURRENT_TIMESTAMP, literal defaults, and expression defaults are all recognized.

Example SQLite schema

Paste this into the tool or upload your own .sql file:

CREATE TABLE IF NOT EXISTS categories (
  id INTEGER PRIMARY KEY AUTOINCREMENT,
  name TEXT NOT NULL UNIQUE,
  description TEXT
);

CREATE TABLE IF NOT EXISTS products (
  id INTEGER PRIMARY KEY AUTOINCREMENT,
  category_id INTEGER NOT NULL,
  name TEXT NOT NULL,
  price REAL NOT NULL DEFAULT 0,
  stock INTEGER DEFAULT 0,
  created_at TEXT DEFAULT CURRENT_TIMESTAMP,
  FOREIGN KEY (category_id) REFERENCES categories(id)
);

CREATE TABLE IF NOT EXISTS orders (
  id INTEGER PRIMARY KEY AUTOINCREMENT,
  product_id INTEGER NOT NULL,
  quantity INTEGER NOT NULL DEFAULT 1,
  total REAL,
  ordered_at TEXT DEFAULT CURRENT_TIMESTAMP,
  FOREIGN KEY (product_id) REFERENCES products(id)
);

How it works

1

Upload or paste

Drop a .sql file from your SQLite project or paste CREATE TABLE statements into the editor.

2

See the diagram

Tables, columns, types, constraints, and foreign key relationships appear as an interactive ER diagram with auto-layout.

3

Explore and export

Click tables to focus on their relationships, click columns to trace specific links, then export as PNG, SVG, SQL, or Excel.