All integrations

Google BigQuery

Connect Google BigQuery to Claude, ChatGPT or Cursor via MCP. Explore datasets, inspect schemas, and run Standard SQL against your GCP projects.

OAuth 6 tools

Overview

Query Google BigQuery datasets, inspect table schemas, and run Standard SQL against GCP projects your Google account can access. This BigQuery MCP integration lets analytics and data agents explore warehouses without exporting CSVs or writing custom scripts.

Common use cases

  • Schema discovery for AI agents — ask Claude or ChatGPT which tables exist in a dataset before writing SQL.
  • Ad hoc analytics — run SELECT queries and summarize results in natural language.
  • Private gateway — combine BigQuery with Gmail, Drive, or other integrations for reporting playbooks.

Prerequisites

  • A Google account with access to a GCP project that has BigQuery enabled
  • IAM roles on that project: BigQuery Data Viewer (read data/metadata) and BigQuery Job User (run queries)
  • A stackgate.ai account

Getting credentials

  1. Open Integrations → Google BigQuery.
  2. Click Activate, then Connect with Google OAuth.
  3. Grant BigQuery read access when Google asks for permission.
  4. Note your GCP Project ID (shown in the Google Cloud Console) — you will pass it to MCP tools.

Using with AI clients

  • Dedicated endpoint: POST /mcp/bigquery
  • Private gateway: bigquery__* tools

Example prompts:

  • List datasets in project my-analytics-project.
  • What columns does my-analytics-project.sales.orders have?
  • Run SELECT date, SUM(revenue) FROM my-analytics-project.sales.orders GROUP BY 1 ORDER BY 1 DESC LIMIT 10.

Use fully qualified table names (project.dataset.table) in SQL queries.

Troubleshooting

  • Permission denied or access denied — verify your Google account has BigQuery Data Viewer and Job User on the target GCP project. Reconnect from My Integrations to refresh OAuth tokens.
  • Project not found — double-check the GCP Project ID (not the project display name).
  • Quota exceeded — query cost and API limits are billed to your GCP project. Check BigQuery quotas in Google Cloud Console or reduce scanned data with filters and limits.
  • Empty dataset list — the connected account may not have bigquery.datasets.get on any dataset in that project.

Available tools

  • list_datasets

    List BigQuery datasets in a GCP project accessible to the connected Google account.

  • get_dataset

    Get metadata for a single BigQuery dataset.

  • list_tables

    List tables in a BigQuery dataset.

  • get_table

    Get schema, partitioning, clustering, and metadata for a BigQuery table.

  • run_query

    Run a Standard SQL query synchronously against a GCP project. Use fully qualified table names.

  • get_query_results

    Fetch additional rows from a BigQuery query job when run_query returns a pageToken or jobComplete is false.

MCP endpoint: https://stackgate.ai/mcp/bigquery (HTTP) or via the private gateway.