MCP server

MCP Toolbox for Databases

Google's open-source MCP server for 20+ databases

Open-source MCP server from Google for connecting agents to databases including AlloyDB, BigQuery, Cloud SQL, Spanner, PostgreSQL, MySQL, SQL Server, MongoDB and more. Offers prebuilt tool sets via --prebuilt or custom tools defined in tools.yaml, with connection pooling and IAM auth.

Also available as

Connect

  1. 1Add the server to Codex
    codex mcp add mcp-toolbox-databases --env POSTGRES_HOST=YOUR_POSTGRES_HOST --env POSTGRES_PORT=YOUR_POSTGRES_PORT --env POSTGRES_DATABASE=YOUR_POSTGRES_DATABASE --env POSTGRES_USER=YOUR_POSTGRES_USER --env POSTGRES_PASSWORD=YOUR_POSTGRES_PASSWORD -- npx -y @toolbox-sdk/server --prebuilt=postgres --stdio

Configs are generated from the publisher's documented endpoint. Check their docs for plan requirements and scopes. New to this? Read the step-by-step tutorial.

Tools 10

execute_sqllist_tableslist_schemaslist_viewslist_indexeslist_active_queriesget_query_plandatabase_overviewlist_lockslist_query_stats

Things to ask

  • “List the tables in my Postgres database”
  • “Show the slowest queries right now”
  • “Explain the query plan for this SELECT”
  • “Which tables are most bloated?”

Related