Skip to content
Back to search

graphite

Desktop SQL client for SQLite, PostgreSQL and MySQL/MariaDB, with an AI assistant and an MCP server for your own agents.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/julioczn--graphite/badge.svg)](/listings/julioczn--graphite)

HTML

<a href="/listings/julioczn--graphite"><img src="/api/listings/julioczn--graphite/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Download the latest build from **[Releases](https://github.com/julioczn/graphite/releases/latest)**.

macOS (Apple Silicon and Intel)

Open `Graphite-<version>-arm64.dmg` (Apple Silicon) or `-x64.dmg` (Intel) and drag Graphite to Applications.

The app is ad-hoc signed but **not notarized** (no paid Apple Developer ID), so Gatekeeper blocks the first launch. Either go to **System Settings → Privacy & Security → Open Anyway**, or run:

xattr -dr com.apple.quarantine /Applications/Graphite.app

On the Mac, shortcuts use `⌘` instead of `Ctrl` (the interface already shows `⌘`), and `⌫` in the grid works as `Del`.

Linux (x64)

sudo apt install ./graphite_<version>_amd64.deb   # Debian/Ubuntu: installs to /opt/Graphite, adds the `graphite` command
sudo apt remove graphite                          # uninstall

Or use the portable `Graphite-<version>.AppImage` (`chmod +x` and run). The `.deb` adds an AppArmor profile so Electron's sandbox works on Ubuntu 23.10+.

TLS / SSL

With **Use SSL**, pick how the server certificate is checked: *encrypt only*, *verify the CA*, or *verify the CA and host name* (the default for new connections). Point to a **CA certificate** (else the system's trusted CAs are used) and, for mutual TLS, a **client certificate and key** (PEM files; Graphite stores only their paths). Firebird encrypts its own protocol instead; MongoDB takes its TLS options in the connection URL (`tls=true&tlsCAFile=…`).

Updates

Graphite checks this repository's releases when it opens and every 6 hours, shows **Update available** in the sidebar, and downloads and installs the new version for you: the file is checked against the SHA-256 that GitHub publishes for it, then Graphite restarts on the new version (macOS `.app`, AppImage, or `.deb` via `pkexec`). Turn the automatic check off in the same dialog; the check is a plain request to the GitHub API with nothing about you or your databases.

Where your data lives

Saved connections, history and settings stay on your machine: `~/Library/Application Support/Graphite` (macOS) or `~/.config/Graphite` (Linux). Graphite has no telemetry; it only talks to your databases, to your AI provider if you set one up, and to GitHub to check for updates (can be turned off).

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 223 lines
  1. <p align="center">
  2. <img src="docs/assets/icon.svg" width="88" height="88" alt="Graphite logo">
  3. </p>
  4. <h1 align="center">Graphite</h1>
  5. <p align="center">
  6. A fast, keyboard-friendly desktop SQL client for <b>SQLite</b>, <b>PostgreSQL</b>, <b>MySQL</b> and friends<br>
  7. with an AI assistant and an MCP server for your own agents.
  8. </p>
  9. <p align="center">
  10. <a href="https://github.com/julioczn/graphite/releases/latest"><img alt="Latest release" src="https://img.shields.io/github/v/release/julioczn/graphite?label=release&color=555"></a>
  11. <a href="https://github.com/julioczn/graphite/actions/workflows/ci.yml"><img alt="CI" src="https://github.com/julioczn/graphite/actions/workflows/ci.yml/badge.svg"></a>
  12. <a href="LICENSE"><img alt="MIT license" src="https://img.shields.io/badge/license-MIT-555"></a>
  13. <img alt="macOS and Linux" src="https://img.shields.io/badge/platform-macOS%20%7C%20Linux-555">
  14. </p>
  15. <p align="center">
  16. <a href="https://julioczn.github.io/graphite/">Website</a> ·
  17. <a href="https://github.com/julioczn/graphite/releases/latest">Download</a> ·
  18. <a href="README.pt-BR.md">Português</a>
  19. </p>
  20. ![Graphite: SQL editor with results](docs/assets/screenshots/query.png)
  21. ## Features
  22. - **SQLite, PostgreSQL, MySQL, MariaDB, TiDB, CockroachDB, GreengageDB and LibSQL/Turso** ([full list](#supported-databases)) with saved connections (passwords encrypted by the OS keychain), a
  23. **Test** button and a ready-to-use **demo** database.
  24. - **SQL editor** (CodeMirror 6): table/column autocomplete, current-statement highlight, several results per run,
  25. inline errors. `⌘/Ctrl+Enter` runs everything or the selection, `⌘/Ctrl+Shift+Enter` runs the statement under the cursor.
  26. - **SQL snippets**: type a shortcut (`sel`, `ij`, `ups`, `ct`…) and pick it from autocomplete; templates adapt to each database.
  27. - **Table browser**: pagination, sorting, `WHERE` filter, structure tab (columns, indexes, DDL).
  28. - **Inline editing** of tables and query results (when the primary key is in the result), applied in a single
  29. transaction. Right-click actions on cells, headers and rows: copy as value / JSON / `INSERT`, set `NULL`, filter by value…
  30. - **Generate SQL** from any table: `SELECT`, `SELECT` with `JOIN`s following the foreign keys, `INSERT`, `UPDATE`, `DELETE`.
  31. - **Auto-commit or manual transactions** per connection, with commit/rollback (PostgreSQL uses savepoints so one error
  32. doesn't abort the transaction).
  33. - **ER diagram** with automatic layout, inferred relations, search, keys-only mode and SVG/PNG export.
  34. - **Backup and restore** in `.sql` / `.sql.gz` without `pg_dump` or `mysqldump`, streamed, with progress and cancel.
  35. - **Export** tables or full query results to CSV, JSON, JSON Lines or SQL `INSERT`s, with no row limit.
  36. - History per connection, saved queries, quick search (`⌘/Ctrl+P`), tabs.
  37. - **English, Português (Brasil) and Español**: follows the system language, switch any time from the globe icon.
  38. <details>
  39. <summary>Snippet shortcuts</summary>
  40. | Query | Joins | Change data | Schema | Diagnostics |
  41. |---|---|---|---|---|
  42. | `sel` `seld` `cnt` `grp` `pag` `busca` `entre` `cte` `case` `exists` `in` `rank` `dup` | `ij` `lj` `rj` `fj` `cj` `antij` `j3` | `ins` `insm` `inss` `insr` `ups` `upd` `updj` `del` `delj` `tx` | `ct` `addcol` `dropcol` `rencol` `idx` `uidx` `fk` `view` `drop` | `exp` `cols` `tam` `proc` |
  43. `Tab` / `Shift+Tab` move between fields and `Esc` leaves. The **Snippets** toolbar button lists them all with search.
  44. </details>
  45. | ER diagram | Approving an agent's change |
  46. |---|---|
  47. | ![ER diagram](docs/assets/screenshots/er.png) | ![Approval dialog](docs/assets/screenshots/approval.png) |
  48. ## Supported databases
  49. | Database | Status | Notes |
  50. |---|---|---|
  51. | SQLite | ✅ | Local files |
  52. | PostgreSQL | ✅ | |
  53. | MySQL | ✅ | |
  54. | MariaDB | ✅ | |
  55. | TiDB | ✅ | AI asks for approval on every query (TiDB doesn't enforce read-only transactions) |
  56. | CockroachDB | ✅ | No Graphite backup (use CockroachDB's own `BACKUP`) |
  57. | GreengageDB | ✅ | |
  58. | LibSQL / Turso | ✅ | Remote URL + token; no manual transaction mode |
  59. | SQL Server / Azure SQL | ✅ | Wide decimals in free-form queries lose precision (driver limitation); `CAST` them |
  60. | Oracle Database | ✅ | Thin mode (no Instant Client); "database" = service name |
  61. | ClickHouse | ✅ | HTTP; no transactions (read-only grid); AI reads with `readonly=1` |
  62. | Trino / Starburst | ✅ | "Database" = `catalog` or `catalog.schema`; read-only grid |
  63. | Firebird 3+ | ✅ | "Database" = path or alias on the server |
  64. | DuckDB | ✅ | Local `.duckdb` file; AI asks for approval on every query |
  65. | Snowflake | 🧪 beta | Programmatic Access Token; read-only grid; not yet tested against a real account |
  66. | BigQuery | 🧪 beta | Service account key (JSON); read-only grid; tested with the open-source emulator |
  67. | MongoDB | ✅ | mongosh-style commands (`db.orders.find({…})`); JSON filter; grid editing keeps BSON types |
  68. | Redis / Valkey | ✅ | redis-cli commands, one per line; keys browsed and edited by type (atomic `MULTI/EXEC`) |
  69. | Apache Cassandra / ScyllaDB | ✅ | CQL; keyspaces in the picker; pages without a total; grid edits as one logged batch |
  70. | Amazon DynamoDB | ✅ | PartiQL; access key + secret (or DynamoDB Local); grid edits in one transaction, attribute types kept |
  71. | SurrealDB | ✅ | SurrealQL over HTTP; namespace + database; grid edits in one transaction, field types kept |
  72. | Amazon Redshift | 🧪 beta | Not yet tested against a real cluster |
  73. | StarRocks | ✅ | No transactions (read-only grid); AI asks for approval on every query |
  74. On the non-relational databases the AI asks for approval on every command, since none of them offers a read-only mode
  75. the app could rely on. They all support grid editing; key columns (`_id`, primary/partition/sort keys, `id`) stay
  76. read-only, since they identify the row.
  77. ## AI: bring your own model or agent
  78. Two ways to use your own AI, sharing the same tools (list connections, schemas and tables, describe a table,
  79. schema summary with foreign keys, run SQL):
  80. - **Built-in assistant** (✦ in the sidebar): a chat next to the editor using the **Anthropic API** (Claude) or any
  81. **OpenAI-compatible** provider, including local models (Ollama, LM Studio). It reads the schema, runs reads on its
  82. own, gives you SQL with **Insert** / **New tab** buttons, and failing queries get a **Fix with AI** button. The model
  83. list is loaded live from the provider. Your API key is encrypted on your machine, stored per provider, and never sent
  84. back to the window or to another provider.
  85. - **MCP server** for external agents (Claude Code, Cursor, VS Code, Claude Desktop via `mcp-remote`): turn it on in
  86. **AI and agents → External agents**, which shows ready-to-paste configs. It only listens on `127.0.0.1`, requires a
  87. token, and rejects browser requests (`Origin`) or other `Host` headers.
  88. ![MCP server settings](docs/assets/screenshots/mcp.png)
  89. **How your data stays safe** ([`electron/lib/aiquery.cjs`](electron/lib/aiquery.cjs)):
  90. - **Reads** (`SELECT`, `WITH`, `EXPLAIN`, `SHOW`…) run in a read-only mode **enforced by the database itself**
  91. (`BEGIN READ ONLY`, `SET SESSION TRANSACTION READ ONLY`, `PRAGMA query_only`), with a 30 s timeout and only the first
  92. rows fetched. A write disguised as a read (`WITH … DELETE`, `EXPLAIN ANALYZE DELETE`, `nextval()`) fails instead of running.
  93. - **Anything else** opens an **approval dialog** in Graphite showing who asked, the connection and every statement.
  94. Approved scripts run in a transaction; rejected ones don't run and the agent is told so. Read-only connections never allow writes.
  95. - Agents use their **own sessions**, never your open transaction. Every call is listed in **AI → Activity**.
  96. > [!IMPORTANT]
  97. > Whoever has the MCP token can **read** every saved connection without asking. Treat it like a password and
  98. > regenerate it if it leaks.
  99. ## Install
  100. Download the latest build from **[Releases](https://github.com/julioczn/graphite/releases/latest)**.
  101. ### macOS (Apple Silicon and Intel)
  102. Open `Graphite-<version>-arm64.dmg` (Apple Silicon) or `-x64.dmg` (Intel) and drag Graphite to Applications.
  103. The app is ad-hoc signed but **not notarized** (no paid Apple Developer ID), so Gatekeeper blocks the first launch.
  104. Either go to **System Settings → Privacy & Security → Open Anyway**, or run:
  105. ```bash
  106. xattr -dr com.apple.quarantine /Applications/Graphite.app
  107. ```
  108. On the Mac, shortcuts use `⌘` instead of `Ctrl` (the interface already shows `⌘`), and `⌫` in the grid works as `Del`.
  109. ### Linux (x64)
  110. ```bash
  111. sudo apt install ./graphite_<version>_amd64.deb # Debian/Ubuntu: installs to /opt/Graphite, adds the `graphite` command
  112. sudo apt remove graphite # uninstall
  113. ```
  114. Or use the portable `Graphite-<version>.AppImage` (`chmod +x` and run). The `.deb` adds an AppArmor profile so
  115. Electron's sandbox works on Ubuntu 23.10+.
  116. ### TLS / SSL
  117. With **Use SSL**, pick how the server certificate is checked: *encrypt only*, *verify the CA*, or *verify the CA and
  118. host name* (the default for new connections). Point to a **CA certificate** (else the system's trusted CAs are used)
  119. and, for mutual TLS, a **client certificate and key** (PEM files; Graphite stores only their paths). Firebird encrypts
  120. its own protocol instead; MongoDB takes its TLS options in the connection URL (`tls=true&tlsCAFile=…`).
  121. ### Updates
  122. Graphite checks this repository's releases when it opens and every 6 hours, shows **Update available** in the
  123. sidebar, and downloads and installs the new version for you: the file is checked against the SHA-256 that GitHub
  124. publishes for it, then Graphite restarts on the new version (macOS `.app`, AppImage, or `.deb` via `pkexec`). Turn the
  125. automatic check off in the same dialog; the check is a plain request to the GitHub API with nothing about you or your
  126. databases.
  127. ### Where your data lives
  128. Saved connections, history and settings stay on your machine: `~/Library/Application Support/Graphite` (macOS) or
  129. `~/.config/Graphite` (Linux). Graphite has no telemetry; it only talks to your databases, to your AI provider if you set one up, and to GitHub to
  130. check for updates (can be turned off).
  131. ## Build from source
  132. Requires **Node.js 22+**.
  133. ```bash
  134. git clone https://github.com/julioczn/graphite.git
  135. cd graphite
  136. npm install
  137. npm run dev # Vite with hot reload + Electron
  138. npm start # production renderer build + Electron
  139. npm run dist:mac # release/Graphite-<version>-{arm64,x64}.dmg and .zip (on a Mac)
  140. npm run dist # release/Graphite-<version>.AppImage and graphite_<version>_amd64.deb
  141. npm run i18n:check # translation coverage
  142. ```
  143. `GRAPHITE_PROFILE_DIR=/some/folder npm start` runs with a separate profile (settings, connections, demo), handy for testing.
  144. ### Project structure
  145. ```
  146. electron/
  147. main.cjs windows, native dialogs, safeStorage, utility process + MessagePorts
  148. preload.cjs window.graphite: RPC over a MessagePort + whitelisted IPC
  149. utility.cjs database process: handlers for conn/*, query/*, table/*, app/*
  150. ai/ hub (tools, agent sessions, approvals), mcp (server), assistant (chat)
  151. drivers/ sqlite, postgres (pg), mysql (mysql2), libsql, mssql (tedious), oracle (oracledb),
  152. clickhouse, trino, firebird (node-firebird), duckdb (@duckdb/node-api),
  153. snowflake, bigquery, mongodb, redis (ioredis), cassandra (cassandra-driver), dynamodb, surrealdb
  154. lib/ app database, demo, backup/restore/export, read-only guard for AI queries
  155. shared/
  156. engines.mjs database engines: family, defaults and capabilities
  157. sql.mjs statement splitter (utility and renderer)
  158. i18n.mjs translations for every process + locales/en.mjs, locales/es.mjs
  159. src/ Vue 3 renderer (components/, lib/)
  160. docs/ website (GitHub Pages) and screenshots
  161. ```
  162. All database work happens in a separate utility process that talks to the window over a `MessagePort`; the window
  163. itself is sandboxed with context isolation and no Node.js access.
  164. ## Translations
  165. The Portuguese text is the translation key: `t('Nova conexão')`, `t('Tabela {name}', { name })`, plurals with
  166. `t('{n} linha|{n} linhas', { n })`. English and Spanish live in [`shared/locales`](shared/locales). To add a language,
  167. copy `en.mjs`, translate the values and register it in [`shared/i18n.mjs`](shared/i18n.mjs);
  168. `npm run i18n:check` lists anything missing. Corrections from native speakers are very welcome.
  169. ## Contributing
  170. Issues and pull requests are welcome. See [CONTRIBUTING.md](CONTRIBUTING.md). For security issues, please follow
  171. [SECURITY.md](SECURITY.md) instead of opening a public issue.
  172. ## License
  173. [MIT](LICENSE) © Julio Zimmermann

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.