MCP Directory

How to add Firebase MCP to Windsurf

Let AI assistants work directly with Firebase Firestore, Storage, and Authentication. Paste the config into ~/.codeium/windsurf/mcp_config.json and restart Windsurf.

Last updated June 14, 2026 · 245 · stdio · apikey

Windsurf config for Firebase MCP

npx -y @gannonh/firebase-mcp
{
  "mcpServers": {
    "firebase-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@gannonh/firebase-mcp"
      ],
      "env": {
        "SERVICE_ACCOUNT_KEY_PATH": "/absolute/path/to/serviceAccountKey.json",
        "FIREBASE_STORAGE_BUCKET": "your-project-id.firebasestorage.app"
      }
    }
  }
}

Setup steps

  1. 1Open Windsurf → Cascade → the hammer/MCP icon → Configure (or edit ~/.codeium/windsurf/mcp_config.json).
  2. 2Paste the Firebase MCP config below.
  3. 3Fill in placeholder secrets, then save.
  4. 4Click Refresh in the MCP panel.
  5. 5Firebase MCP's tools become available to Cascade.

Before you start

  • Firebase project with service account credentials
  • Node.js environment
  • FIREBASE_STORAGE_BUCKET (optional; defaults to [projectId].appspot.com)

What Firebase MCP can do in Windsurf

firestore_add_document

Add a document to a collection. Required parameters: collection, data.

firestore_list_documents

List documents with filtering. Required parameter: collection.

firestore_get_document

Get a specific document. Required parameters: collection, id.

firestore_update_document

Update an existing document. Required parameters: collection, id, data.

firestore_delete_document

Delete a document. Required parameters: collection, id.

firestore_list_collections

List root collections. No required parameters.

firestore_query_collection_group

Query across subcollections. Required parameter: collectionId.

storage_list_files

List files in a directory. No required parameters (optional: directoryPath).

Security

Requires a Firebase service account key JSON file (set via SERVICE_ACCOUNT_KEY_PATH). The service account grants administrative access to your Firebase project via the Admin SDK — store the key securely and grant it only the permissions needed for the Firebase services you intend to use.

Firebase MCP + Windsurf FAQ

Where is the Windsurf config file?

Windsurf reads MCP servers from ~/.codeium/windsurf/mcp_config.json. Paste the Firebase MCP config there under the "mcpServers" key and restart the client.

Is Firebase MCP safe to use with Windsurf?

Requires a Firebase service account key JSON file (set via SERVICE_ACCOUNT_KEY_PATH). The service account grants administrative access to your Firebase project via the Admin SDK — store the key securely and grant it only the permissions needed for the Firebase services you intend to use.

How do I install and configure it?

Add the server config to your MCP client settings (e.g. Claude Desktop, Cursor, VS Code/Augment). The recommended approach uses npx: set command to "npx" with args ["-y", "@gannonh/firebase-mcp"] and provide SERVICE_ACCOUNT_KEY_PATH (and optionally FIREBASE_STORAGE_BUCKET) as env vars. You can also run a local build with node pointing at dist/index.js.

What credentials does it need?

A Firebase service account key JSON file. Generate one in Firebase Console → Project Settings → Service Accounts → Generate new private key, then set SERVICE_ACCOUNT_KEY_PATH to its absolute path.

Does it support HTTP transport?

Yes. Set MCP_TRANSPORT=http (with optional MCP_HTTP_PORT, MCP_HTTP_HOST, MCP_HTTP_PATH) to run as a standalone HTTP service. Clients then connect via a url such as http://localhost:3000/mcp. HTTP transport supports session management for multiple concurrent clients.

View repo Full Firebase MCP page