Documentation / Getting started
Introduction
OpenDB is an AI agent that queries, updates and documents your SQL databases in plain language, without your data leaving your infrastructure unless you want it to.
What OpenDB is
OpenDB connects a language model to a relational database. You ask a question in English or French, the agent explores the schema, writes the SQL, runs it and shows you the result. Any operation that changes the database waits for your approval.
OpenDB works with MySQL, MariaDB, PostgreSQL and SQLite. It is free and open source.
A few things you can ask the agent:
- "Which tables exist?"
- "Show me last month's cancelled orders"
- "Chart the revenue by month"
- "Why is this query slow?"
- "Delete the carts abandoned more than six months ago"
The last request stops on an approval request that shows the query and the number of rows affected.
The four workspaces of a project
A project brings together a database connection, a working folder on your disk, your conversations and some settings. Once open, it offers four workspaces.
| Workspace | What it is for |
|---|---|
| Chat | Talk to the agent: questions, results, charts, writes subject to approval |
| Tables | Browse and edit data in a grid, design a table, import and export |
| SQL editor | Write and run scripts, read an execution plan, get help from the AI |
| ERD schema | See the database diagram, diagnose the schema, design tables with an assistant |
The workspaces talk to each other. From a row in the grid, "Ask the chat" opens a conversation with a prepared question. From the diagram, you open a table's data or a new query.

Your data stays under your control
OpenDB is designed so that the model knows as little as possible about your data.
- Local model. With Ollama, the model runs on your machine or on your own server. Nothing leaves.
- Anonymized clone. Before using a third-party provider, you can clone the database while replacing personal data, column by column. The agent works on the copy.
- Tables kept out of sight. You choose which tables the agent may read.
- Results shown without going through the model. The tables, key figures and charts in the chat are loaded by your browser. The model only receives their description. See Artifacts.
- Human approval. Deletions, structure changes, emails: none of these run without you.
The Security and privacy page details each protection.
Three ways to use OpenDB
- The web interface, in your browser, with the four workspaces.
- The terminal, with
opendb chatand the administration commands. See Chat in the terminal. - An external agent such as Claude Code, Cursor or Zed, which queries a project in read-only mode through the MCP server.
Where to start
- Install OpenDB.
- Follow the quick start: an AI provider, a project, a first question.