Run SQL and database commands through MCP across remote databases and local SQLite, DuckDB, or H2 files.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
We haven't yet run this listing's install command through our automated sandbox check. This isn't a red flag β we're steadily working through the catalog.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Inspect callable tools, capabilities, and parameters exposed to AI agents by SQLX.
The SQLX MCP server gives an agent access to database connections through the SQLX CLI and MCP. It can work with remote database services such as MySQL, MariaDB, PostgreSQL, CockroachDB, Oracle, SQL Server, ClickHouse, Trino, Presto, Redis, and MongoDB. It can also open local SQLite, DuckDB, and H2 files.
Connections are created as named datasources and stored in encrypted form. An agent can test a datasource, run one or more SQL statements, or send database-specific commands. SQLX returns complete structured results rather than requiring the agent to parse terminal text.
The SQLX MCP server runs through the sqlx mcp command. Agent integrations start that process and invoke its exposed operations. The Codex plugin starts the MCP process directly; its read-only operations can run without approval, while sqlx_sql_execute and sqlx_sql_view are treated as destructive and require approval by default.
SQLX selects a worker based on the datasource type. Some engines use native workers, while others use JDBC workers with downloaded database support and a private JRE when needed. The CLI accepts multiple --command values in a single invocation. For Redis, each command is a Redis command rather than SQL; MongoDB uses one command document per command.
Release packages are available for macOS ARM64 and x64, Linux ARM64 and x64, and Windows x64. Installation can use GitHub Releases, platform scripts, or npx @ottermind/sqlx@latest; the npx route requires Node.js 22 or newer for installation, but Node.js is not needed by the installed CLI. The Linux release baseline is Ubuntu 24.04.
After installation, create and test a datasource with commands such as:
Codex and Claude Code provide plugins, while DeepSeek Harness and Pi have their own packages. A managed Skill can also be installed for Codex, Claude, dsh, Pi, or another agentβs skill directory. Codex and Claude Code plugins install the CLI when it is missing and enforce their documented minimum CLI version.
The SQLX MCP server covers these operations and connection patterns:
Supported datasource types include MySQL, MariaDB, TiDB, GreatSQL, OceanBase, StarRocks, Apache Doris, PostgreSQL, CockroachDB, YugabyteDB, openGauss, Oracle, SQL Server, ClickHouse, Trino, Presto, Hive, Apache Kylin, TDengine, Dameng, KingbaseES, XuguDB, Redis, MongoDB, SQLite, DuckDB, and H2.
The CLI installers support the listed release targets; the prebuilt package does not cover every operating system or architecture. Oracle requires a service name, Trino and Presto require a catalog or schema database value, and local SQLite or DuckDB connections use a file path instead of host credentials. Presto requires a username, and its password is sent only over TLS.
Installing or updating the CLI does not automatically update Skills or plugins. A separate sqlx skill update command updates managed Skills. The SQLX_NO_UPDATE_CHECK=1 setting disables the interactive background update check, while piped and CI commands skip that check automatically.
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/sqlx)<a href="https://allmcps.com/mcp/sqlx"><img src="https://allmcps.com/api/badge/sqlx?style=directory" alt="SQLX on AllMCPs" /></a>