Is the Google Cloud MCP server safe? What it can reach
What the Google Cloud MCP server can read, write and delete, how it signs in, and how to limit it in Claude Code and Codex.
Google runs hosted MCP servers for many Google Cloud products, each at its own googleapis.com/mcp endpoint, and also publishes the open source gcloud-mcp servers in preview. Both act with your Google identity. The most consequential tool is run_gcloud_command, and the control that matters is a least-privilege service account.
Who maintains it
| Implementation | Kind | Status |
|---|---|---|
| Google Cloud remote MCP servers (per product) | Official | active |
| googleapis/gcloud-mcp (preview, not an officially supported Google product) | Official | active |
It runs as a local process on your machine or as a hosted remote server. The documented endpoint is https://bigquery.googleapis.com/mcp.
How it signs in
The hosted servers use Google identities and need the MCP Tool User role (roles/mcp.toolUser) plus the IAM roles of the underlying service. The local gcloud server uses the active gcloud account.
| Scope or permission | Access |
|---|---|
roles/mcp.toolUser | read |
What its tools can do
| Kind | Tools |
|---|---|
| Read | list_log_entries, list_log_names, list_buckets, list_views, list_sinks, list_log_scopes, list_metric_descriptors, list_time_series, list_alert_policies, list_traces, get_trace, list_group_stats, list_objects, read_object_metadata, read_object_content, get_bucket_metadata, get_bucket_location, view_iam_policy, check_iam_permissions, get_metadata_table_schema, execute_insights_query, list_insights_configs, list_backup_vaults, get_backup_vault, list_backup_plans, get_backup_plan, list_backup_plan_associations, get_backup_plan_association, list_datasources, get_datasource, list_backups, get_backup, find_protectable_resources, get_backupdr_operation, get_csql_operation |
| Write | write_object, update_object_metadata, copy_object, upload_object, download_object, create_bucket, update_bucket_labels, create_backup_vault, create_backup_plan, update_backup_plan, create_backup_plan_association |
| Can’t be undone | run_gcloud_command, delete_object, move_object, delete_bucket, restore_backup, csql_restore, delete_backup_vault, delete_backup_plan, delete_backup_plan_association, delete_backup |
These are the tools of the open source gcloud-mcp packages (gcloud, observability, storage, backupdr). The hosted per-product servers each have their own tool list in Google’s product guides, which this record does not cover. run_gcloud_command runs any gcloud command that is not on its default deny list.
Built-in limits
| Option | What it does |
|---|---|
Service account impersonation | Google recommends running the gcloud server as a service account with a limited role. |
gcloud deny list | The gcloud server blocks commands that take arbitrary input or start interactive sessions by default. |
IAM allow and deny policies | Hosted Google Cloud MCP servers support IAM policies, so you can limit who can call what on which resources. |
Per-toolset endpoints | Each toolset has its own HTTP endpoint and works as its own virtual server, which limits the tools an agent sees. |
Model Armor | Can scan hosted MCP requests and responses for prompt injection and sensitive data. |
The risks
- run_gcloud_command passes a command string to the gcloud CLI, so an injected instruction can run anything your active account is allowed to do, in any project it can reach.
- The storage tools can read object contents and delete or move objects and buckets, which is a path to data loss and to leaking bucket data into the conversation.
- The backup tools can delete vaults, plans and backups, and restore over live data.
- The gcloud server inherits your active account, so a personal owner account gives the agent owner rights.
Limit it in Claude Code
Add it from the documented launch settings, at local or user scope so a token never lands in a shared .mcp.json:
claude mcp add gcloud -- npx -y @google-cloud/gcloud-mcpClaude Code names MCP tools mcp__gcloud__<tool>. Deny rules win over ask rules, and ask rules over allow rules. Put these in ~/.claude/settings.json or the project’s .claude/settings.json:
{
"permissions": {
"deny": [
"mcp__gcloud__delete_object",
"mcp__gcloud__move_object",
"mcp__gcloud__delete_bucket",
"mcp__gcloud__restore_backup",
"mcp__gcloud__csql_restore",
"mcp__gcloud__delete_backup_vault",
"mcp__gcloud__delete_backup_plan",
"mcp__gcloud__delete_backup_plan_association",
"mcp__gcloud__delete_backup"
],
"ask": [
"mcp__gcloud__run_gcloud_command",
"mcp__gcloud__write_object",
"mcp__gcloud__upload_object",
"mcp__gcloud__update_object_metadata",
"mcp__gcloud__copy_object",
"mcp__gcloud__create_bucket",
"mcp__gcloud__update_bucket_labels",
"mcp__gcloud__create_backup_vault",
"mcp__gcloud__create_backup_plan",
"mcp__gcloud__update_backup_plan",
"mcp__gcloud__create_backup_plan_association"
]
}
}Limit it in Codex
Codex reads MCP servers from ~/.codex/config.toml. disabled_tools removes tools, and enabled_tools keeps only the ones you list:
[mcp_servers.gcloud]
command = "npx"
args = ["-y", "@google-cloud/gcloud-mcp"]
disabled_tools = ["delete_object", "move_object", "delete_bucket", "restore_backup", "csql_restore", "delete_backup_vault", "delete_backup_plan", "delete_backup_plan_association", "delete_backup"]Checklist
- Run the server as a service account with a narrow role, not your own account.
- Deny the delete and restore tools you do not need.
- Ask before run_gcloud_command runs.
- Grant roles/mcp.toolUser only on the project you work in.
- Pin the package version, since the repo warns of breaking changes.
Checked against the vendor documentation on November 25, 2026. googleapis/gcloud-mcp README · Google Cloud MCP servers overview · Supported products and endpoints · Manage MCP servers
What Excellent covers
Excellent doesn’t inspect MCP servers themselves. Its free scan reads supported logs on the Mac (Claude Code, Codex, Grok Build, GitHub Copilot CLI, Gemini CLI and Qwen Code) and reports findings for review, so you can see what an agent did after a session. Run the free scan · See a sample report · How to vet any MCP server
Excellent Pro adds checks before supported actions. Claude Code can display an ask prompt. With Codex, an Excellent “ask” refuses the action and tells the agent to ask you. Pro is US-only for now. Agent coverage · Pricing