Search...Search plugins and themes...
⌘K
Sign in
  • Get started
  • Download
  • Pricing
  • Enterprise
  • Account
  • Obsidian
  • Overview
  • Sync
  • Publish
  • Canvas
  • Mobile
  • Web Clipper
  • CLI
  • Learn
  • Help
  • Developers
  • Changelog
  • About
  • Roadmap
  • Blog
  • Resources
  • System status
  • License overview
  • Terms of service
  • Privacy policy
  • Security
  • Community
  • Plugins
  • Themes
  • Discord
  • Forum / 中文论坛
  • Merch store
  • Brand guidelines
Follow us
DiscordTwitterBlueskyThreadsMastodonYouTubeGitHub
© 2026 Obsidian

ObDrawDB

hzchzc26 downloads

Visual database diagram editor (ER diagrams) powered by drawdb. Create, edit and export database schemas as .drawdb files.

  • Overview
  • Scorecard
  • Updates4

A visual database diagram editor (ER diagrams) for Obsidian, powered by drawdb.

Create, edit, and export relational database schemas directly inside your vault using .drawdb files — fully compatible with the drawdb JSON format.

DrawDB screenshot


Features

  • Visual ER diagram editor — drag-and-drop tables on an infinite canvas
  • Table & field management — add/edit/delete tables and fields with types, constraints, and comments
  • Relationships — draw foreign key relationships between fields with configurable cardinality and ON UPDATE/DELETE behavior
  • Multi-database support — MySQL, PostgreSQL, SQLite, MSSQL, MariaDB field types
  • Export SQL — generate CREATE TABLE + ALTER TABLE FOREIGN KEY statements
  • Undo / Redo — full history with Ctrl+Z / Ctrl+Shift+Z
  • Pan & zoom — mouse wheel zoom, middle-button / Space+drag pan, Fit-to-screen
  • drawdb compatible — .drawdb files use the same JSON format as drawdb.io, so diagrams can be opened and edited in either tool
  • Light & dark theme — adapts to your Obsidian theme automatically

Usage

Create a new diagram

  • Click the database icon in the left ribbon, or
  • Run the command DrawDB: New diagram from the command palette

A new diagram.drawdb file is created in your vault root and opened in the editor.

Open an existing .drawdb file

Click any .drawdb file in the file explorer — it opens automatically in the DrawDB editor.

Editing

Action How
Add a table Click + Table in the toolbar, or double-click an empty area on the canvas
Move a table Drag the colored header
Select a table Click the header; properties appear in the right panel
Edit a field Click a field row in the right panel to expand its properties
Add a field Click + Add Field in the right panel
Delete a table Select it, then click Delete Table in the right panel, or press Delete
Draw a relationship Switch to Draw Relation mode, click a source field, then click a target field
Delete a relationship Click the line on the canvas to select it, then click Delete Relationship, or press Delete
Pan the canvas Hold Space and drag, or use the middle mouse button
Zoom Scroll the mouse wheel (zooms toward cursor)
Fit all tables Click Fit in the toolbar
Save Click Save or press Ctrl+S (Cmd+S on Mac)
Undo / Redo Ctrl+Z / Ctrl+Shift+Z
Export SQL Click Export SQL — downloads schema.sql

Installation

Manual install (development / testing)

  1. Build the plugin:
    npm install
    npm run build
    
  2. Copy main.js, manifest.json, and styles.css to:
    <YourVault>/.obsidian/plugins/obsidian-drawdb/
    
  3. In Obsidian: Settings → Community plugins → Reload plugins, then enable DrawDB.

Community plugin store

Coming soon — once submitted to the Obsidian community plugin list.


File format

.drawdb files are plain JSON and fully compatible with the drawdb.io web app. Example:

{
  "database": "MySQL",
  "tables": [
    {
      "id": 1,
      "name": "users",
      "x": 80,
      "y": 60,
      "color": "#175e7a",
      "comment": "",
      "fields": [
        {
          "id": 2,
          "name": "id",
          "type": "INT",
          "primary": true,
          "unique": true,
          "notnull": true,
          "autoincrement": true,
          "default": "",
          "size": "",
          "comment": "",
          "check": "",
          "values": []
        }
      ],
      "indices": []
    }
  ],
  "references": [],
  "notes": [],
  "areas": []
}

Settings

Settings → DrawDB

Setting Description
Default database type Database type assigned to newly created diagrams (MySQL, PostgreSQL, SQLite, MSSQL, MariaDB)

Development

# Install dependencies
npm install

# Watch mode (auto-recompile on save)
npm run dev

# Production build
npm run build

# Lint
npm run lint

Requirements: Node.js 18+, npm.


License

MIT


Acknowledgements

  • drawdb-io/drawdb — the original open-source ER diagram editor this plugin is based on
  • obsidianmd/obsidian-sample-plugin — plugin template
84%
HealthExcellent
ReviewCaution
About
Create visual ER diagrams and edit relational schemas directly inside your vault using .drawdb files. Manage tables, fields and foreign-key relationships with drag-and-drop editing, multi-database field types, and generate SQL CREATE/ALTER statements for MySQL, PostgreSQL, SQLite, MSSQL and MariaDB.
CanvasDataExport
Details
Current version
0.1.3
Last updated
Last week
Created
Last week
Updates
4 releases
Downloads
26
Compatible with
Obsidian 0.16.0+
Platforms
Desktop, Mobile
License
MIT
Report bugRequest featureReport plugin
Author
hzchzchanzhichao
GitHubhanzhichao
  1. Community
  2. Plugins
  3. Canvas
  4. ObDrawDB

Related plugins

Advanced Canvas

Supercharge your canvas experience. Create presentations, flowcharts and more.

Tracker

Track occurrences and numbers in your notes.

Datacore

An even faster reactive query engine for the data obsessed.

Meld Encrypt

Hide secrets in your notes.

Pandoc Plugin

Commands to export to Pandoc-supported formats like DOCX, ePub and PDF.

Mood Tracker

Track your moods & emotions easily. Visualize tracked history and browse the past entries.

Timekeep

Time tracking.

Keep the Rhythm

Turns out watching your word count go up is all the motivation you need.

Yanki

Sync flashcards from a folder in your vault to Anki. Pure Markdown syntax. No fuss.

Charted Roots

Family tree visualization with GEDCOM/Gramps import and Canvas/PDF/Markdown export. Charts, maps, timelines, citations, fictional calendars. For genealogists, worldbuilders, and TTRPG campaigns.