MCP Directory

How to add Multi Database MCP Server to Cursor

Give AI assistants structured access to MySQL, PostgreSQL, SQLite, Oracle, and TimescaleDB simultaneously. Paste the config into ~/.cursor/mcp.json and restart Cursor.

Last updated June 14, 2026 · 392 · stdio · no auth

Cursor config for Multi Database MCP Server

docker pull freepeak/db-mcp-server:latest
{
  "mcpServers": {
    "multi-database-mcp-server": {
      "command": "/path/to/db-mcp-server/server",
      "args": [
        "-t",
        "stdio",
        "-c",
        "/path/to/config.json"
      ]
    }
  }
}

Setup steps

  1. 1Open Cursor → Settings → MCP → Add new MCP server (or edit ~/.cursor/mcp.json directly).
  2. 2Paste the Multi Database MCP Server config below into the "mcpServers" object.
  3. 3Fill in placeholder secrets, then save.
  4. 4Cursor reloads MCP servers automatically — check Settings → MCP for a green status dot.
  5. 5Ask Cursor to use one of Multi Database MCP Server's tools to confirm it's connected.

Before you start

  • A built server binary (via `make build` from source) or the freepeak/db-mcp-server Docker image
  • A config.json file declaring your database connections (or inline JSON via -db-config / DB_CONFIG)
  • Network access and valid credentials for the target databases (MySQL, PostgreSQL, SQLite, Oracle, and/or TimescaleDB)

What Multi Database MCP Server can do in Cursor

query_<db_id>

Execute SELECT queries and get results as a tabular dataset.

execute_<db_id>

Run data manipulation statements (INSERT, UPDATE, DELETE).

transaction_<db_id>

Begin, commit, and rollback transactions.

schema_<db_id>

Get information about tables, columns, indexes, and foreign keys.

generate_schema_<db_id>

Generate SQL or code from the database schema.

performance_<db_id>

Analyze query performance and get optimization suggestions.

timescaledb_<db_id>

Perform general TimescaleDB operations (PostgreSQL with the TimescaleDB extension).

create_hypertable_<db_id>

Convert a standard table to a TimescaleDB hypertable.

Security

Database credentials (host, user, password, encryption keys, Oracle wallet paths) are stored in the config.json file or passed via the -db-config flag / DB_CONFIG environment variable; protect this file and avoid committing it. The generated execute_<db_id> and transaction_<db_id> tools allow data-modifying SQL (INSERT/UPDATE/DELETE), so connect with a database user scoped to the minimum required privileges. SQLite supports SQLCipher encryption and read-only mode for sensitive databases.

Multi Database MCP Server + Cursor FAQ

Where is the Cursor config file?

Cursor reads MCP servers from ~/.cursor/mcp.json. Paste the Multi Database MCP Server config there under the "mcpServers" key and restart the client.

Is Multi Database MCP Server safe to use with Cursor?

Database credentials (host, user, password, encryption keys, Oracle wallet paths) are stored in the config.json file or passed via the -db-config flag / DB_CONFIG environment variable; protect this file and avoid committing it. The generated execute_<db_id> and transaction_<db_id> tools allow data-modifying SQL (INSERT/UPDATE/DELETE), so connect with a database user scoped to the minimum required privileges. SQLite supports SQLCipher encryption and read-only mode for sensitive databases.

Which databases are supported?

MySQL, PostgreSQL (v9.6-17), SQLite (file-based and in-memory, with SQLCipher encryption), Oracle (10g-23c, including RAC, Cloud Wallet, and TNS), and TimescaleDB.

How do the tools get their names?

Tools are generated per connection using the connection's id. For a database with id 'mysql1' the server creates query_mysql1, execute_mysql1, transaction_mysql1, schema_mysql1, performance_mysql1, and so on.

What transport modes are available?

STDIO mode (`-t stdio`) for IDE integration such as Cursor, and SSE mode (`-t sse`, default localhost:9092) for Server-Sent-Events / HTTP clients. The Docker image defaults to SSE via TRANSPORT_MODE=sse.

View repo Full Multi Database MCP Server page