← Back to directory
F

Firebase MCP Server

Community
MCP server that lets AI assistants work directly with Firebase services
GitHub source repository ↗
★ 248 Stars Category · Database Popular
54FMRS · D

Maintained by community developer gannonh (not official Google tooling), MIT licensed, with reasonably complete tool coverage, detailed documentation, test CI, and Firebase emulator-based tests. Well suited to developers with existing Firebase projects using mainstream MCP clients; pay attention to service account key security and the known Zod validation log issue.

Reliability
9/20
Security and permissions
6/20
Maintenance
11/20
Documentation
15/20
Setup experience
13/20
Read the FMRS scoring method →

Firebase MCP is an open-source (MIT licensed) Model Context Protocol server that enables AI assistants to work directly with Firebase services, including Firestore document database operations, Firebase Storage file management with robust upload capabilities, and Authentication user lookup. It can be installed via npx or locally with Node.js, uses stdio transport by default, and also supports HTTP transport for shared multi-client access. It works with MCP clients such as Claude Desktop, Augment Code, VS Code, and Cursor.

Tools

firestore_add_document
Add a document to a collection
firestore_list_documents
List documents in a collection with filtering
firestore_get_document
Get a specific document
firestore_update_document
Update an existing document
firestore_delete_document
Delete a document
firestore_list_collections
List root collections
firestore_query_collection_group
Query across subcollections
storage_list_files
List files in a directory
storage_get_file_info
Get file metadata and URL
storage_upload
Upload file from content
storage_upload_from_url
Upload file from URL
auth_get_user
Get user by ID or email

Setup

  1. In the Firebase Console, go to Project Settings → Service Accounts and generate a new private key JSON file; store it securely. 2. Add the server configuration to your MCP client settings file (e.g., Claude Desktop's claude_desktop_config.); npx is recommended: command 'npx', args ["-y","@gannonh/firebase-mcp"]. 3. Set the required SERVICE_ACCOUNT_KEY_PATH environment variable (absolute path to the key JSON) and optionally FIREBASE_STORAGE_BUCKET (defaults to [projectId].appspot.com). 4. Optionally configure HTTP transport (MCP_TRANSPORT=http, MCP_HTTP_PORT, etc.) or debug logging (DEBUG_LOG_FILE). 5. Verify installation by asking your AI client to test all Firebase MCP tools.
claude_desktop_config.json
{"firebase-mcp":{"command":"npx","args":["-y","@gannonh/firebase-mcp"],"env":{"SERVICE_ACCOUNT_KEY_PATH":"/absolute/path/to/serviceAccountKey.","FIREBASE_STORAGE_BUCKET":"your-project-id.firebasestorage.app"}}}

Fit and risk

Best for

  • Developers with data already in Firebase who want AI assistants to read and write it directly
  • Users of MCP clients such as Claude Desktop, Cursor, VS Code, or Augment Code
  • Workflows combining document database, file storage, and user lookup

Not for

  • Users without a Firebase project or service account credentials
  • Firebase administration tasks such as project management or function deployment
  • Environments without an MCP client or the ability to configure environment variables

Required permissions

  • Requires a Firebase service account private key JSON file (SERVICE_ACCOUNT_KEY_PATH)
  • The service account must have proper permissions for Firestore, Storage, and Authentication services
  • Requires a Firebase Storage bucket name, either configured or defaulted

Risks and side effects

  • Service account private keys carry broad privileges; misconfiguration or leakage can expose full data access
  • AI assistants can delete Firestore documents and upload/overwrite storage files, creating risk of unintended operations
  • The firestore_list_collections tool may trigger a Zod validation error in client logs (a known MCP SDK issue that does not affect functionality but may cause confusion)
  • Some Firestore queries require manually creating composite indexes in the Firebase Console

Troubleshooting

  1. For 'The specified bucket does not exist', verify the bucket name in the Firebase Console and set FIREBASE_STORAGE_BUCKET correctly
  2. For 'Firebase is not initialized', check that the service account key path is a correct absolute path and the account has proper permissions
  3. For composite index errors, follow the URL in the error message to create the index in the Firebase Console, then retry
  4. The Zod validation error on firestore_list_collections is a known log-level issue and does not affect functionality
  5. Enable file logging via DEBUG_LOG_FILE (default ~/.firebase-mcp/debug.log) or use MCP Inspector for interactive debugging

Use cases

CRUD operations and subcollection queries on Firestore through an AI assistant
Managing files in Firebase Storage: listing, retrieving metadata, uploading from content or URL
Looking up Firebase Authentication users by ID or email
Running as a standalone HTTP service shared by multiple clients

Supported clients

Claude DesktopFull support
Augment CodeFull support
VS CodeFull support
CursorFull support