dbdesk

PostgreSQL · MySQL · MariaDB · SQLite · SQL Server · DuckDB · ClickHouse

Seven databases, one native app

dbdesk is a desktop database tool written in Rust. Write SQL with completion from your catalog, edit rows in the grid, change tables without writing the DDL, keep production safe, and let an AI assistant in only as far as you allow.

Also for Linux: AppImage · .deb · every download

Expanding a SQLite data source's tables, typing SELECT * FROM orders with completion's help, running it, and having the database filter the 60 orders to the open ones and sort them, newest first.

Native

Rust and egui, with no browser engine or JVM inside. The Linux AppImage is 39 MB, the universal Mac app 78 MB.

Careful with production

A safety level per data source, from asking before risky statements to read-only, and a colour that makes production stand out.

AI assistants, with permissions

A built-in MCP server, off until you allow a project, with read, write, schema and admin rights for each one.

Features

Writing SQL

SQL that knows your schema

Completion suggests tables after FROM and columns after an alias, and follows CTEs and subqueries; cid finds customer_id. Problems are marked as you type: = NULL, an UPDATE without WHERE, an unknown column, and what the database itself says.

  • Run the statement at the cursor or the whole script, explain it, cancel it.
  • Format a statement or a whole console, leaving strings and comments alone.
  • Open, save and drop in .sql files; edits made elsewhere are picked up.
  • :name parameters, asked for as you run; find and replace with regular expressions.
Query consoles in the manual
A console with a wavy underline under = NULL, explained as never true: use IS NULL

The results grid

A grid that edits, and asks the database

Rows arrive 500 at a time. Sort and filter the rows loaded, or tick In the database to have it sort and filter every row.

  • Edit cells, add and delete rows, then submit them together or revert.
  • Follow a foreign key to the row it points at, or list the rows pointing back.
  • Export the loaded rows, or stream every row, to CSV or JSON.
  • Import a CSV file into a table, with a preview and warnings first.
Working with table data in the manual
The grid with a changed email, a row marked for deletion and a new row, waiting to be submitted

Changing the schema

Change the schema without writing the DDL

Dialogs for tables, indexes, views and materialized views, schemas, and PostgreSQL users and roles write the SQL and show it. Nothing runs until you press Execute, or open it in a console instead.

  • Modify table renames, adds and changes columns, and says what each database can change in place; SQLite's table is rebuilt for the rest.
  • A change of several statements runs in one transaction where the database can, and warns first where it can't.
  • Copy any table's DDL.
Creating and changing tables in the manual
Modify table on orders, with a column renamed and one added, and the ALTER TABLE statements it will run

Staying safe

Careful where it matters

Each data source has a safety level. Normal asks before an UPDATE or DELETE without WHERE. Careful asks before every change, naming the data source, and opens consoles in manual commit. Read-only refuses changes, and on PostgreSQL, MySQL, MariaDB and SQLite the database enforces it too.

  • A colour per data source, on its tree row, its console tabs and a band across the console.
  • Manual-commit transactions, and a question before closing one that's open.
  • A history of every statement, from consoles, the grid, dialogs, imports and assistants, with the grid's values before and after.
  • Passwords stay in the system keychain, and out of the history.
Safety levels in the manual
A careful data source asking whether to run an UPDATE on shop before it runs

AI assistants through MCP

Let an assistant in, as far as you allow

dbdesk includes an MCP server. Allow a project, copy its configuration into Claude Desktop, Claude Code, Cursor or another client, and the assistant can list, describe, explain and query that project's data sources, with the dbdesk window closed.

  • Off until you allow a project.
  • Read, write, schema and admin permissions per project, a row limit and a statement timeout.
  • Checked three times: dbdesk parses each statement, runs reads in a read-only transaction, and the database's own grants apply.
  • An optional login of its own, and every statement in the history, marked with the assistant's name.
Connecting an AI assistant in the manual
A project's settings allowing MCP clients, with read and write ticked, a row limit and a statement timeout

Connecting anywhere

Reach the database where it runs

PostgreSQL, MySQL, MariaDB, SQL Server and Azure SQL, ClickHouse over HTTP, and DuckDB and SQLite files.

  • SSH tunnels on every server database, through your agent, a key file or a password, with host keys checked against known_hosts.
  • TLS up to verify-full, with your own CA file and no OpenSSL to install.
  • ${VARIABLE} placeholders in connection settings.
  • Projects to group data sources, and a file to move them to another machine, without their passwords.
Data sources in the manual
A PostgreSQL data source reached through an SSH server, signing in with a key file

Making it yours

Bend it with plain files

dbdesk keeps its settings in files you can read and edit, next to each other.

  • keymap.toml rebinds the shortcuts.
  • actions.toml adds your own SQL to the explorer's and the grid's menus, with names and values quoted for you.
  • snippets.toml adds snippets to completion, with fields to Tab through.
  • theme.toml changes the light and dark themes' colours.
  • On a Mac, the menus are in the menu bar, and text takes the system font and accent colour.
Actions, snippets and themes in the manual
# actions.toml
[[action]]
id = "row-count"
name = "Row count"
applies_to = ["table", "view"]
sql = "SELECT count(*) FROM {qualified_name}"

# snippets.toml
[[snippet]]
trigger = "sel"
body = "SELECT ${1:*}\nFROM ${2:table};"

# theme.toml
[dark]
primary = "#9a8bff"

Databases

Oracle is planned.

Download dbdesk v0.12.0

macOS

A universal app for Apple silicon and Intel, macOS 11 or newer.

.dmg

Not signed by Apple yet, so the first launch needs Open Anyway.

Windows

An installer for Windows 10 and 11 on 64-bit Intel and AMD. It installs dbdesk for you alone, without administrator rights.

Installer

Not signed yet, so SmartScreen blocks the first run: More info, then Run anyway.

It updates itself

dbdesk asks GitHub for a newer release when it starts, or from Help › Check for updates…. On macOS and in the AppImage, Install and restart checks the update's signature and puts it in place, and installed Windows copies do the same from the next release; the .deb opens the release page instead. The check sends nothing about you, and can be turned off.

Check what you downloaded

Every release has a SHA256SUMS file. In the folder with your download:

shasum -a 256 -c SHA256SUMS --ignore-missing

Free and open source under MIT or Apache-2.0. The source, every release and the design docs are on GitHub.