BigQuery MCP Server
Enables LLMs to securely converse with BigQuery data using natural language.
Key Features
Use Cases
README
BigQuery MCP Server
What is this? π€
This is a server that lets your LLMs (like Claude) talk directly to your BigQuery data! Think of it as a friendly translator that sits between your AI assistant and your database, making sure they can chat securely and efficiently.
Quick Example
You: "What were our top 10 customers last month?"
Claude: *queries your BigQuery database and gives you the answer in plain English*
No more writing SQL queries by hand - just chat naturally with your data!
How Does It Work? π οΈ
This server uses the Model Context Protocol (MCP), which is like a universal translator for AI-database communication. While MCP is designed to work with any AI model, right now it's available as a developer preview in Claude Desktop.
Here's all you need to do:
- Set up authentication (see below)
- Add your project details to Claude Desktop's config file
- Start chatting with your BigQuery data naturally!
What Can It Do? π
- Run SQL queries by just asking questions in plain English
- Access both tables and materialized views in your datasets
- Explore dataset schemas with clear labeling of resource types (tables vs views)
- Analyze data within safe limits (1GB query limit by default)
- Keep your data secure (read-only access)
Quick Start π
Prerequisites
- Node.js 14 or higher
- Google Cloud project with BigQuery enabled
- Either Google Cloud CLI installed or a service account key file
- Claude Desktop (currently the only supported LLM interface)
Option 1: Quick Install via Smithery (Recommended)
To install BigQuery MCP Server for Claude Desktop automatically via Smithery, run this command in your terminal:
npx @smithery/cli install @ergut/mcp-bigquery-server --client claude
The installer will prompt you for:
- Your Google Cloud project ID
- BigQuery location (defaults to us-central1)
Once configured, Smithery will automatically update your Claude Desktop configuration and restart the application.
Option 2: Manual Setup
If you prefer manual configuration or need more control:
-
Authenticate with Google Cloud (choose one method):
- Using Google Cloud CLI (great for development):
bash
gcloud auth application-default login - Using a service account (recommended for production):
bash
# Save your service account key file and use --key-file parameter # Remember to keep your service account key file secure and never commit it to version control
- Using Google Cloud CLI (great for development):
-
Add to your Claude Desktop config Add this to your
claude_desktop_config.json:-
Basic configuration:
json{ "mcpServers": { "bigquery": { "command": "npx", "args": [ "-y", "@ergut/mcp-bigquery-server", "--project-id", "your-project-id", "--location", "us-central1" ] } } } -
With service account:
json{ "mcpServers": { "bigquery": { "command": "npx", "args": [ "-y", "@ergut/mcp-bigquery-server", "--project-id", "your-project-id", "--location", "us-central1", "--key-file", "/path/to/service-account-key.json" ] } } }
-
-
Start chatting! Open Claude Desktop and start asking questions about your data.
Command Line Arguments
The server accepts the following arguments:
--project-id: (Required) Your Google Cloud project ID--location: (Optional) BigQuery location, defaults to 'us-central1'--key-file: (Optional) Path to service account key JSON file
Example using service account:
npx @ergut/mcp-bigquery-server --project-id your-project-id --location europe-west1 --key-file /path/to/key.json
Permissions Needed
You'll need one of these:
roles/bigquery.user(recommended)- OR both:
roles/bigquery.dataViewerroles/bigquery.jobUser
Developer Setup (Optional) π§
Want to customize or contribute? Here's how to set it up locally:
# Clone and install
git clone https://github.com/ergut/mcp-bigquery-server
cd mcp-bigquery-server
npm install
# Build
npm run build
Then update your Claude Desktop config to point to your local build:
{
"mcpServers": {
"bigquery": {
"command": "node",
"args": [
"/path/to/your/clone/mcp-bigquery-server/dist/index.js",
"--project-id",
"your-project-id",
"--location",
"us-central1",
"--key-file",
"/path/to/service-account-key.json"
]
}
}
}
Current Limitations β οΈ
- MCP support is currently only available in Claude Desktop (developer preview)
- Connections are limited to local MCP servers running on the same machine
- Queries are read-only with a 1GB processing limit
- While both tables and views are supported, some complex view types might have limitations
Support & Resources π¬
- π Report issues
- π‘ Feature requests
- π Documentation
License π
MIT License - See LICENSE file for details.
Author βοΈ
Salih ErgΓΌt
Sponsorship
This project is proudly sponsored by:
Version History π
See CHANGELOG.md for updates and version history.
Star History
Repository Owner
User
Repository Details
Programming Languages
Tags
Topics
Join Our Newsletter
Stay updated with the latest AI tools, news, and offers by subscribing to our weekly newsletter.
Related MCPs
Discover similar Model Context Protocol servers
BigQuery MCP Server
MCP server enabling LLMs to access and interact with BigQuery databases.
BigQuery MCP Server provides a Model Context Protocol-compliant interface that allows large language models to inspect database schemas and execute SQL queries on BigQuery. It exposes tools for executing queries, listing tables, and describing table schemas, supporting both CLI and environment-based configuration. The server integrates with Claude Desktop and can be easily installed via Smithery, facilitating seamless interaction between LLMs and BigQuery data sources.
- β 120
- MCP
- LucasHild/mcp-server-bigquery
PGMCP
Natural language PostgreSQL interface via the Model Context Protocol.
PGMCP enables seamless interaction with any PostgreSQL database through natural language queries, translating user intent into structured SQL results. It acts as a Model Context Protocol (MCP) server, connecting AI assistants and MCP-compatible clients to databases with features like streaming, robust error handling, and optional AI-powered SQL generation. The tool ensures secure, read-only access to existing databases using HTTP/MCP protocol. Compatibility includes tools such as Cursor, Claude Desktop, and VS Code extensions.
- β 499
- MCP
- subnetmarco/pgmcp
mcp-graphql
Enables LLMs to interact dynamically with GraphQL APIs via Model Context Protocol.
mcp-graphql provides a Model Context Protocol (MCP) server that allows large language models to discover and interact with GraphQL APIs. The implementation facilitates schema introspection, exposes the GraphQL schema as a resource, and enables secure query and mutation execution based on configuration. It supports configuration through environment variables, automated or manual installation options, and offers flexibility in using local or remote schema files. By default, mutation operations are disabled for security, but can be enabled if required.
- β 319
- MCP
- blurrah/mcp-graphql
XiYan MCP Server
A server enabling natural language queries to SQL databases via the Model Context Protocol.
XiYan MCP Server is a Model Context Protocol (MCP) compliant server that allows users to query SQL databases such as MySQL and PostgreSQL using natural language. It leverages the XiYanSQL model, providing state-of-the-art text-to-SQL translation and supports both general LLMs and local deployment for enhanced security. The server lists available database tables as resources and can read table contents, making it simple to integrate with different applications.
- β 218
- MCP
- XGenerationLab/xiyan_mcp_server
Databricks Genie MCP Server
Bridge natural language queries to Databricks Genie via Model Context Protocol.
Databricks Genie MCP Server enables interaction between large language models and the Databricks Genie API using the Model Context Protocol. It allows users to ask natural language questions, start and manage conversations, and run SQL queries in Genie spaces. The tool provides structured results, supports follow-up queries, and facilitates connection through both standard and Docker-based setups. Designed for use with Claude Desktop, it streamlines conversational analytics within Databricks workspaces.
- β 12
- MCP
- yashshingvi/databricks-genie-MCP
greptimedb-mcp-server
A Model Context Protocol (MCP) server for secure, structured AI access to GreptimeDB.
greptimedb-mcp-server implements a Model Context Protocol (MCP) server for GreptimeDB, enabling AI assistants to securely explore and analyze database contents. It provides controlled operations such as listing tables, reading data, and executing SQL queries, ensuring responsible access. The server offers integration with Claude Desktop and supports prompt management for structured AI interactions.
- β 23
- MCP
- GreptimeTeam/greptimedb-mcp-server
Didn't find tool you were looking for?