@renzo.johnson/firebase-mcp
v26.11.15
Published
Firebase MCP server for Claude Code, Cursor, Copilot and five more AI agents. mcprush.com-bea9c94c1cc9f6dd34244b94
Maintainers
Readme
Firebase MCP
Firebase MCP server for Claude Code, Cursor, Copilot and five more AI agents. This is the MCP server from the Firebase MCP VS Code extension, packaged to run with npx in any MCP client.
Requires Node.js 22 or newer.
npx -y @renzo.johnson/firebase-mcpThe server speaks MCP over stdio, so you normally let your AI agent start it, as below.
Claude Code
claude mcp add firebase-mcp -- npx -y @renzo.johnson/firebase-mcpOr add it to .mcp.json in your project (or ~/.claude.json for every project):
{
"mcpServers": {
"firebase-mcp": {
"command": "npx",
"args": ["-y", "@renzo.johnson/firebase-mcp"],
"env": {
"GOOGLE_APPLICATION_CREDENTIALS": "/path/to/service-account.json"
}
}
}
}Cursor
Add the same block to ~/.cursor/mcp.json (or .cursor/mcp.json in a project):
{
"mcpServers": {
"firebase-mcp": {
"command": "npx",
"args": ["-y", "@renzo.johnson/firebase-mcp"],
"env": {
"GOOGLE_APPLICATION_CREDENTIALS": "/path/to/service-account.json"
}
}
}
}Credentials
The server signs in to Google in this order:
| Option | Environment | Best for |
|--------|-------------|----------|
| OAuth user | GOOGLE_OAUTH_CLIENT_ID, GOOGLE_OAUTH_CLIENT_SECRET, GOOGLE_OAUTH_REFRESH_TOKEN (all three) | Personal Google accounts |
| Service account or saved credentials | GOOGLE_APPLICATION_CREDENTIALS = path to a JSON key | Servers, Workspace admins |
| gcloud | none: run gcloud auth application-default login once | Developers with the Google Cloud CLI |
Setting only some of the three OAuth variables stops the server with an error that names the missing ones. Enable the Cloud Firestore API and the Identity Toolkit API in your Google Cloud project.
Optional settings:
| Variable | What it does |
|----------|--------------|
| FIREBASE_MCP_PROJECT_ID | Firebase project ID used when a request does not name one |
Set firebaseMcp.projectId to your Firebase project ID, or pass project_id in a request. A service account key from Project settings > Service accounts is the simplest sign-in. The account needs the Cloud Datastore Viewer and Firebase Authentication Viewer roles.
Available Tools (8)
| Tool | What It Does | Example Prompt |
|------|-------------|----------------|
| firestore_list_collections | Top-level collections or a document's subcollections | "List my Firestore collections" |
| firestore_get_document | Read one document | "Show orders/1234" |
| firestore_query | Query a collection with filters, order and limit | "The 10 newest unpaid orders" |
| firestore_count | Count documents without reading them | "How many users signed up today?" |
| auth_get_user | Look up a user by UID, email or phone | "Find the user [email protected]" |
| auth_list_users | List Authentication users | "List the first 100 users" |
Firebase Admin (firebase_admin)
One tool, called with an action and its params.
| Action | Needs confirm: true |
|--------|----------------------|
| create_document(path, data) | No |
| set_document(path, data, merge?) | Yes |
| update_document(path, data) | No |
| delete_document(path) | Yes |
| create_user(email?, password?, display_name?, phone?, email_verified?) | No |
| update_user(uid, email?, password?, display_name?, phone?, email_verified?) | No |
| disable_user(uid, disabled?) | No |
| delete_user(uid) | Yes |
set_document replaces the whole document, so it needs confirm: true unless merge is true. create_document never overwrites.
Safety
Actions that delete, remove, replace or publish need confirm: true in their params. Without it the server changes nothing and returns a warning, so your AI agent has to ask you and then call again with confirm: true.
VS Code
Prefer a setup wizard that registers the server with eight agents for you? Install the Firebase MCP extension instead (also on the VS Code Marketplace). Use one or the other, not both.
