Google's toolbox for Postgres, MySQL, BigQuery, Spanner and other databases.
- Started in our test
- ★ 16.7K GitHub stars
- 31.2K downloads a week
- Last commit 25 Oct 2026
At a glance
Toolbox is a server from Google that ships ready-made tool sets for a long list of databases. Pick one with --prebuilt and pass connection details as environment variables, or write your own tools file to expose only the queries you approve.
That second option is the reason to choose it: you can give an assistant five named queries instead of raw SQL.
- Made by
- Google (googleapis)
- Licence
- Apache-2.0
- Latest version
- 1.15.0 (23 Oct 2026)
- npm package
- @toolbox-sdk/server
- GitHub stars
- 16.7K
- Downloads
- 31.2K a week
- Last commit
- 25 Oct 2026
- Tools
- 29
- Runs on
- Your computer
Our check: We ran this exact config on 26 Oct 2026: it started and answered with 29 tools. @toolbox-sdk/server on npm is published from googleapis/mcp-toolbox.
What's in the pod: its tools
We found 29 tools when we started it on 26 Oct 2026. 22 only read. The rest can change things, so keep your app's "ask before each tool call" setting on for them.
How we tested it: Started with the published config against a local Postgres 16 database.
Runs commands1 tool · Can start programs or run code.
| Tool | What it is for |
|---|---|
execute_sql | Runs a SQL statement the agent writes against the connected database. |
Changes things6 tools · Can create, edit, send or delete.
| Tool | What it is for |
|---|---|
get_query_plan | Shows how Postgres would run a query, as JSON, without running it. |
list_autovacuum_configurations | Shows the server's autovacuum settings. |
list_invalid_indexes | Finds broken indexes that take space but the planner cannot use. |
list_memory_configurations | Shows the server's memory settings. |
list_replication_slots | Lists replication slots and how far behind each one is. |
list_top_bloated_tables | Finds the tables with the most dead rows waiting to be cleaned up. |
Only reads22 tools · Looks things up and changes nothing.
| Tool | What it is for |
|---|---|
database_overview | Gives a quick snapshot of the server: version, uptime, whether it is a replica and connection counts. |
get_column_cardinality | Estimates how many distinct values each column of a table holds. |
list_active_queries | Shows the queries running right now, longest first. |
list_available_extensions | Lists extensions that could be installed on this server. |
list_database_stats | Shows activity and size figures for each database on the server. |
list_indexes | Lists your indexes with their size and how often they are used. |
list_installed_extensions | Lists the extensions already installed. |
list_locks | Shows which sessions hold locks and on what. |
list_pg_settings | Lists server configuration values. |
list_publication_tables | Lists tables included in logical replication publications. |
list_query_stats | Ranks past queries by total time, from pg_stat_statements. |
list_roles | Lists the user roles and their rights. |
list_schemas | Lists the schemas in the database. |
list_sequences | Lists sequences and their current values. |
list_stored_procedure | Lists stored procedures with their language and definition. |
list_table_stats | Shows table activity, such as sequential scans and row counts. |
list_tables | Lists the tables in the database with their columns, so the agent learns the schema. |
list_tablespaces | Lists tablespaces and their size. |
list_triggers | Lists triggers and which tables they fire on. |
list_views | Lists views and their definitions. |
long_running_transactions | Finds transactions that have been open longer than a limit you set. |
replication_stats | Shows each replica's lag and connection details. |
Tool groups
--prebuilt=postgres- Ready-made tools for PostgreSQL. Swap the name for mysql, sqlserver, oracle, mongodb, redis, snowflake, clickhouse, neo4j and more.
--prebuilt=bigquery- Google Cloud data: also alloydb-postgres, cloud-sql-postgres, cloud-sql-mysql, spanner and firestore.
--prebuilt=<database>/<toolset>- Load only part of a prebuilt set, such as the data tools without the admin ones.
tools.yaml- Your own tools: fixed, parameterised queries you write once, so the agent can only run what you allowed.
Grouped and described by us. The README on GitHub lists the inputs each tool takes.
Set it up
Pick your app for the exact snippet and where it goes.
Where it goes: claude_desktop_config.json (Settings → Developer → Edit Config)
{
"mcpServers": {
"mcp-toolbox-for-databases": {
"command": "npx",
"args": [
"-y",
"@toolbox-sdk/server",
"--prebuilt=postgres",
"--stdio"
],
"env": {
"POSTGRES_HOST": "localhost",
"POSTGRES_PORT": "5432",
"POSTGRES_DATABASE": "dbname",
"POSTGRES_USER": "user",
"POSTGRES_PASSWORD": "password"
}
}
}
}Where it goes: Your terminal, in the project folder
claude mcp add-json mcp-toolbox-for-databases '{"command":"npx","args":["-y","@toolbox-sdk/server","--prebuilt=postgres","--stdio"],"env":{"POSTGRES_HOST":"localhost","POSTGRES_PORT":"5432","POSTGRES_DATABASE":"dbname","POSTGRES_USER":"user","POSTGRES_PASSWORD":"password"}}'Where it goes: ~/.cursor/mcp.json, or .cursor/mcp.json in a project
{
"mcpServers": {
"mcp-toolbox-for-databases": {
"command": "npx",
"args": [
"-y",
"@toolbox-sdk/server",
"--prebuilt=postgres",
"--stdio"
],
"env": {
"POSTGRES_HOST": "localhost",
"POSTGRES_PORT": "5432",
"POSTGRES_DATABASE": "dbname",
"POSTGRES_USER": "user",
"POSTGRES_PASSWORD": "password"
}
}
}
}Where it goes: .vscode/mcp.json in your project
{
"servers": {
"mcp-toolbox-for-databases": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@toolbox-sdk/server",
"--prebuilt=postgres",
"--stdio"
],
"env": {
"POSTGRES_HOST": "localhost",
"POSTGRES_PORT": "5432",
"POSTGRES_DATABASE": "dbname",
"POSTGRES_USER": "user",
"POSTGRES_PASSWORD": "password"
}
}
}
}Where it goes: ~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"mcp-toolbox-for-databases": {
"command": "npx",
"args": [
"-y",
"@toolbox-sdk/server",
"--prebuilt=postgres",
"--stdio"
],
"env": {
"POSTGRES_HOST": "localhost",
"POSTGRES_PORT": "5432",
"POSTGRES_DATABASE": "dbname",
"POSTGRES_USER": "user",
"POSTGRES_PASSWORD": "password"
}
}
}
}Where it goes: Not supported
ChatGPT only connects to remote servers by URL. This one runs on your computer, so use Claude, Cursor or VS Code.
New to this? See the setup guides for Claude Code, Cursor, Claude Desktop and ChatGPT.
Settings
Names are exactly as the project spells them. Required ones are marked.
| Setting | What it does |
|---|---|
--prebuiltCommand line flag | Starts with a ready-made tool set for one database type, with no config file.--prebuilt=postgres |
--stdioCommand line flag | Talks to a client over standard input and output, which most desktop clients need. |
--configCommand line flag | Path to a tools.yaml that defines your sources, tools and toolsets.--config tools.yaml |
POSTGRES_HOSTEnvironment variable | Connection details for the prebuilt Postgres tools, alongside POSTGRES_PORT, POSTGRES_DATABASE, POSTGRES_USER and POSTGRES_PASSWORD. Other databases use their own names. |
--uiCommand line flag | Opens a local web page to try out your tools before an agent uses them. |
--telemetry-otlpCommand line flag | Sends traces and metrics to any OpenTelemetry collector. |
What it can touch
It can read
- Whichever databases you configure as sources, from Postgres and MySQL to BigQuery and MongoDB
It can change
- Data, if you load a prebuilt set with execute_sql or write tools that update rows
- Nothing else when you only define read queries in tools.yaml
Safer setup: Skip the prebuilt execute_sql and write your own tools.yaml with fixed queries, and give the database user read-only rights.
Before you start
- Node.js 18 or newer
- Connection details for your database
If it does not work
- Prebuilt tools cannot connect
- Each database expects its own environment variables. Check the prebuilt tools reference for the exact names and set them in the client config.
- The client only shows some tools
- You may be connected to a toolset URL. Use /mcp for everything or /mcp/<toolset> for one group.
- Unsure whether a custom tool works
- Run toolbox --ui and try it by hand first.
Peas in a pod: similar servers
How MCP Toolbox for Databases lines up against other databases and data servers on the shelf.
| Server | Tools | Runs on | Licence | Stars |
|---|---|---|---|---|
| MCP Toolbox for Databases | 29 | Your computer | Apache-2.0 | 16.7K |
| Qdrant | 2 | Your computer | Apache-2.0 | 1.6K |
| Excel MCP Server | 46 | Your computer | MIT | 4.3K |
| Postgres MCP Pro | 9 | Your computer | MIT | 3.4K |
| Supabase | 29 | Hosted | – | 3K |
Questions
Is it only for Google Cloud?
No. It covers Google databases such as BigQuery, AlloyDB and Spanner, and also Postgres, MySQL, SQL Server, Oracle, MongoDB, Redis, Snowflake and many more.
Why write tools.yaml instead of letting the AI write SQL?
Predefined queries limit the agent to safe, tested actions, which suits production data.
Can I use it from my own app?
Yes. SDKs for Python, JavaScript, Go and Java load the same tools into LangChain, LlamaIndex, Google ADK and other frameworks.
Is it free?
Yes, Apache 2.0 licensed. Google also sells managed MCP servers for its databases if you would rather not host it.
Something wrong on this page? Tell us.