Free online tools to generate, calculate,
convert, format, encode, and play.
 

Database Schema Designer

Visually design a database; create tables, define columns with types, draw relationships, then export as SQL CREATE statements or a diagram image. Everything runs in your browser.


Dialect
No tables yet. Click Add Table to start.

SQL Output


    

How It Works

Designing Your Schema
  1. Add tables — click Add Table to drop a new entity onto the canvas; drag its header to reposition it.
  2. Edit columns — click a table to open the editor, then add columns and choose a data type for each.
  3. Set constraints — mark a column as Primary Key (PK), Not Null (NN), or Unique (UQ) with the checkboxes.
  4. Draw relationships — in the References field, point a column at another table's column to create a foreign key; a connecting line is drawn automatically.
  5. Export — generate SQL CREATE TABLE statements for PostgreSQL, MySQL, or SQLite, or save the diagram as a PNG image.
Foreign Keys & Relationships

A foreign key links a column in one table to a column (usually the primary key) in another table. Set the References dropdown on a column to the target table.column; the designer draws a line between the two tables and emits a FOREIGN KEY ... REFERENCES clause in the generated SQL.

SQL Dialects
  • PostgreSQL — uses SERIAL for auto-increment primary keys and double-quoted identifiers where needed.
  • MySQL — uses AUTO_INCREMENT and backtick-quoted identifiers.
  • SQLite — uses INTEGER PRIMARY KEY AUTOINCREMENT and a flexible type system.
Privacy

All modeling, SQL generation, and image export happen entirely in your browser with JavaScript; your schema is never uploaded to a server. Use Save to download the design as a JSON file you can re-Load later.


Embed This Util

You can embed this util on your own site as a widget. Adding ?embed=1 to the URL loads a compact version with just the tool itself; no header, menu, or documentation. Paste this snippet into your HTML:


    

Copy snippet Adjust the height to taste.



Feedback

Help us improve this page by providing feedback, and include your name/email if you want us to reach back. Thank you in advance.


Share with