Skip to content

ChartDB

Web editor that turns one query into an editable database schema diagram

Copyleft (OSI) · AGPL-3.0
  • Self-hosted

Listed by , founder & editor

56

Health

Active

Overview

Stars

23,167

Last commit

23 days ago

Nov 2026

Repository age

2 years

since Aug 2024

Latest version

v1.21.0

Nov 2026

Contributors

–

3 active in 90 days

Releases

6

last 12 months

Language

TypeScript

ChartDB is a web-based editor for database diagrams. You run a single query in your database, paste the resulting JSON into the app, and it draws the schema. You can then rearrange tables, annotate them and export SQL scripts. No account is needed.

It supports PostgreSQL, MySQL, SQL Server, MariaDB, SQLite including Cloudflare D1, CockroachDB and ClickHouse. An optional AI export generates DDL in another dialect, for example when moving from MySQL to PostgreSQL. This needs an OpenAI API key or a custom OpenAI-compatible endpoint, such as a local vLLM server.

The app is built with TypeScript and React. You can use the hosted version, run npm install and npm run dev, or deploy the Docker image from ghcr.io on port 8080. Analytics through Fathom can be turned off with a flag. It is AGPL-3.0 licensed and in public beta. It suits people who use tools like dbdiagram or Lucidchart for ER diagrams and want to host their own.

Who it's for

Backend developers documenting an existing database

One query pulls the real schema, so you skip drawing tables by hand.

Skip if: You need general flowcharts or whiteboards rather than database diagrams.

Teams migrating between database engines

AI export can produce DDL in the target dialect from your current schema.

Skip if: You cannot send schema details to an OpenAI service or run your own compatible model.

Self-hosters who keep schema data in-house

A single Docker image serves the app on your network.

Skip if: AGPL-3.0 obligations are a problem for your organization.

The problem it solves

Understanding or documenting a database schema usually means drawing diagrams by hand or exporting from heavy tools. This reads your schema from one query and gives you an editable diagram you can host yourself.

Strengths

  • Imports a live schema from one query as JSON
  • Supports seven database families including ClickHouse and CockroachDB
  • Exports SQL scripts, with AI-assisted dialect conversion
  • Runs from a single Docker image or npm build
  • Works without an account

Trade-offs

  • Public beta status
  • AI features need an OpenAI key or a compatible endpoint
  • AGPL-3.0 license has network-use obligations
  • Only 3 contributors in the last 90 days

Self-host ChartDB

Self-hostable
Yes
Hosted plan
From $25/month · pricing

Quick start

docker run -e OPENAI_API_KEY=<YOUR_OPEN_AI_KEY> -p 8080:80 ghcr.io/chartdb/chartdb:latest

From the project's own install instructions. Check the docs for production settings.

Frequently asked questions

Is it free and self-hostable?

Yes. The code is AGPL-3.0 and you can run it with Docker or npm. A paid hosted plan also exists.

Which databases does it support?

PostgreSQL, MySQL, SQL Server, MariaDB, SQLite with Cloudflare D1, CockroachDB and ClickHouse.

Do I need an account?

No. All features work without one.

Can I use a local AI model?

Yes. Set a custom OpenAI-compatible endpoint and model name, such as a local vLLM server.

Similar tools in Diagramming and whiteboard tools

Gaphor

Diagramming and whiteboard tools

Desktop modeling tool for UML, SysML, RAAML and C4 diagrams, scriptable in Python

2.3k 247 7 days ago Active Apache-2.0

Replaces Microsoft Visio

draw.io

Diagramming and whiteboard tools

Browser-based diagram editor for flowcharts, UML and network diagrams you can self-host

9.6k 1.4k 6 days ago Active Apache-2.0

Replaces Miro

OpenBoard

Diagramming and whiteboard tools

Interactive whiteboard app for classrooms on Windows, macOS and Debian

3.1k 540 10 days ago Active GPL-3.0

Azimutt

Diagramming and whiteboard tools

Database schema explorer and ERD tool for teams with large, messy databases

2.2k 144 3 months ago Dormant MIT

Freeplane

Diagramming and whiteboard tools

Free Java mind mapping desktop app with scripting, for personal and work notes

4.5k 508 yesterday Active GPL-2.0

Replaces Xmind

UMLet

Diagramming and whiteboard tools

Lightweight UML drawing tool for quick diagrams, with export to PDF, SVG and EPS

1.6k 321 13 months ago Dormant GPL-3.0