Read-only PostgreSQL, Oracle and SQL Server access for AI agents: SQL, plans, schema, index stats
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
One-click editor setup isnβt available for this listing yet β we donβt have a confirmed install command, and weβd rather show nothing than point your editor at the wrong package or host. Follow the projectβs own setup instructions, linked above.
MCP server (stdio) that exposes read-only access to relational databases over JDBC: schema
metadata, SELECT execution, execution plans, statistics and index analysis. Built-in dialects
for PostgreSQL, Oracle, SQL Server, Firebird and SQLite (drivers bundled); other databases are
served through DatabaseMetaData with an external driver.
Contents: Features Β· Typical Scenarios Β· Quickstart Β· Architecture Β· MCP Tools Β· MCP Resources Β· Read-only Protection Β· Server Environment Variables Β· Build Β· Stack Β· Troubleshooting Β· License
driverPath. Capabilities per engine: Supported Databases.SELECT / WITH / EXPLAIN), plus
session-, transaction- or file-level read-only mode where the engine supports it. Details:
Read-only Protection.connections.json;
every tool takes a connection argument; pools are created on first use. Credentials are not
read from the environment.The agent picks the tools itself; these are the chains it usually follows. Every tool is described in MCP Tools.
| Scenario | Example request | Tools |
|---|---|---|
| Answer a data question | "How many orders did each region ship last month?" | queryContext or schemaBrief β describeTable β findJoinPaths β validateQuery β executeQuery |
| Explore an unfamiliar schema | "What does the billing schema hold, and how are its tables related?" | schemaBrief β tableContext β sampleRows β schemaGraphDot |
| Check a query before running it | "Is this report query correct, and which tables does it really read?" | inspectQuery β queryLint β resolveQueryLineage β analyzePlan |
| Speed up a slow query | "Why is this query slow, and which index would help?" | analyzePlan β tableStats, indexStats β estimateSelectivity, columnDistribution, joinCardinality β benchmarkQuery |
| Audit indexes and schema | "Find missing and redundant indexes in the orders schema." | fkIndexCoverage, redundantIndexes, unusedIndexes, schemaLint |
| Learn from existing application SQL | "How does the application usually join customers and invoices?" | findQueriesByTable, findQueriesByColumn, observedRelationships |
1. Get the jar β download jdbc-mcp-server.jar from the
latest release (JDK 21+ required;
all JDBC drivers are bundled), or build it yourself:
No local JDK? Use the Docker image ghcr.io/igorolv/jdbc-mcp-server instead β see
Docker.
2. Describe your databases in ~/.jdbc-mcp-server/connections.json
(%USERPROFILE%\.jdbc-mcp-server\connections.json on Windows, /data/connections.json in the
Docker image) β one entry per database, keyed by the connection name:
url is the only required field; the engine is detected from its prefix. Any other URL needs a
driverPath to a driver jar and is served as generic JDBC.description is returned by listConnections, so an agent picks a database by meaning; name the
stand and any restriction ("PRODUCTION β keep queries small").archive opens a local Firebird file in-process: nativeLibraryPath is the directory holding
libfbclient.so / fbclient.dll with its engine and plugins. Point it at a copy of the file β
see Firebird.Every field, naming rules, ${VAR} secrets and several stands of one service:
docs/connections.md.
3. Register the server with your MCP client β with no database settings in the client config:
For Claude Code and Codex CLI that is one command:
OpenCode, VS Code with Copilot, Copilot CLI, Cursor, Claude Desktop, Qwen Code, and tips that apply to every client: docs/clients.md.
4. Try it. Ask the agent in plain words:
listConnections and lists the entries of your
connections.json with their descriptions.orders?" β it calls listTables on that connection and counts
them.If the first call against a database fails, see Checking a configuration.
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/jdbc-mcp-server)<a href="https://allmcps.com/mcp/jdbc-mcp-server"><img src="https://allmcps.com/api/badge/jdbc-mcp-server?style=directory" alt="JDBC MCP Server on AllMCPs" /></a>