# Firebase — card for AI agents

Backend platform with database, authentication, hosting, and serverless functions.

Maker: Google · category: Databases and backends

## Price (official page)
- Free tier: Spark plan with generous no-cost limits (1 GiB storage, 20K writes/day, 50K reads/day, 2M function invocations/month, etc.)
- Free tier terms: free allowance · monthly · card not needed (read from the wording above and the pricing page; empty = not stated)
- Usage price: Varies by service (e.g., $0.20/GiB bandwidth, $0.10/GB storage, $0.40/million invocations, $5/GB Realtime DB)
- Pricing page: https://firebase.google.com/pricing (checked 2026-10-09)
- Note: Added automatically: its SDK was in 195 of the public agent repos we sampled when it was added; integrations in LlamaIndex. Prices read from the official pricing page.

## Connect
- npm: `npm install firebase`
- Repository: https://github.com/firebase/firebase-js-sdk

## For AI agents on Google's own site (AgentGid check 2026-11-13: 3 of 6)
- llms.txt: https://firebase.google.com/llms.txt
- Docs pages as Markdown: 100% of the pages llms.txt lists
- OpenAPI description: none found at the usual places
- Official MCP server: no · official SDK: yes · status page: no
- robots.txt lets AI assistants (ChatGPT-User, Claude-User) read the site: yes

## A year of price history (Internet Archive copies of the pricing page, read by rules)
- Months read: 13 (2025-10 to 2026-10) of https://firebase.google.com/pricing
- Lowest $/month figure on the page: $9.37 in 2025-10, $9.37 in 2026-10
- A figure is any "$X/month" on the page (plans, seats and add-ons alike); open the archived copy to see which plan it is.

## Price history in AgentGid's catalog (since 2026-10-09)
- Changes recorded: 0 (a vendor price change or an editor's correction; the evidence archive keeps the pricing page of each date)

## Other APIs in this category
- MongoDB Atlas: https://agentgid.com/apis/mongodb/agent.md
- DuckDB: https://agentgid.com/apis/duckdb/agent.md
- Redis: https://agentgid.com/apis/redis/agent.md
- Upstash Redis: https://agentgid.com/apis/upstash/agent.md
- Neon: https://agentgid.com/apis/neon/agent.md

## Links
- AgentGid page: https://agentgid.com/apis/firebase/


## Firebase: Google's ready back end for web and mobile apps

Firebase is a set of ready online services from Google for apps and websites, including a database, sign-in for your users, file storage, hosting and server code. Your app talks to them straight from the browser or phone, and rules you write decide who may read or change what. Small apps fit the free Spark plan; bigger ones pay as they go.

### Where to use it
- Sign-up and login for your app: Let people create an account with email and password, or with Google and other providers, without writing your own login system.
- Save each user's data: Store profiles, notes, orders or game progress in a cloud database that the app reads and writes directly.
- Live chat and live status: Show new chat messages or an order's status the moment they change, without reloading the page.
- Put your website online: Publish a static site or single-page app to fast global hosting with one command, with your own domain and free SSL.
- Push notifications to phones: Send reminders and news to your app's users as push messages, at no cost.
- Profile photos and uploads: Let users upload an avatar or attach files, and show them back in the app from cloud storage. (idea, not from the official pages)

### How to start
- Create a Firebase project in the console and register your web app to get its config object.
- Install the JavaScript package.

```
npm install firebase
```

- Initialize Firebase with the config, then add the services you use, such as Firestore and Authentication.

```
import { initializeApp } from 'firebase/app';
// TODO: Replace the following with your app's Firebase configuration
const firebaseConfig = {
  //...
};
const app = initializeApp(firebaseConfig);
```


### License
Firebase is a Google service for business use, free on the Spark plan and paid by use on Blaze. The JavaScript and Admin packages are open source under Apache-2.0.

### Good to know
- Test mode lets anyone read and overwrite your database. Write proper Security Rules before real users arrive.
- The web key in your app is meant to be public; your data is protected by Security Rules and App Check.
- Trusted server code with the Firebase admin package skips Security Rules, so it must check permissions itself.
- Server functions and higher usage need the pay-as-you-go Blaze plan with a billing account.
- Unless you choose a location, Google may store the data in any of its data centers; sign-in runs only in the US.

Checked 2026-11-10 against: https://firebase.google.com/, https://firebase.google.com/pricing, https://firebase.google.com/terms, https://firebase.google.com/support/privacy, https://firebase.google.com/docs/projects/api-keys, https://firebase.google.com/docs/web/setup, https://firebase.google.com/docs/admin/setup, https://firebase.google.com/docs/auth/web/start, https://firebase.google.com/docs/reference/rest/auth, https://firebase.google.com/docs/firestore/quickstart, https://firebase.google.com/docs/firestore/quotas, https://firebase.google.com/docs/firestore/query-data/listen, https://firebase.google.com/docs/firestore/security/get-started, https://firebase.google.com/docs/hosting, https://firebase.google.com/docs/ai-assistance/mcp-server, https://registry.npmjs.org/firebase/13.2.0, https://registry.npmjs.org/firebase-admin/14.5.0

### Mistakes to avoid
- Don't: Leaving Firestore in test mode, or rules like allow read, write if true, after launch. → Do: Start in production mode or write rules that check request.auth and the user's own document path. (Test mode lets anyone read and overwrite your data.)
- Don't: Hiding the Firebase web key on a server and thinking the data is now safe. → Do: Keep the web key in the app config and protect data with Security Rules and App Check. (Firebase web keys are public by design; they only identify the project.)
- Don't: Allowing the Gemini Developer API on the same public Firebase web key. → Do: Use a separate, restricted key for other Google APIs, or call Gemini through Firebase AI Logic. (A public key with Gemini enabled lets anyone spend your quota.)
- Don't: Putting the service account key file in the repository or the front end. → Do: Keep it on the server and point GOOGLE_APPLICATION_CREDENTIALS at it. (The Admin SDK with this key bypasses all Security Rules.)
- Don't: Old namespaced code such as firebase.firestore().collection('users').add(...). → Do: Use the modular API: import { collection, addDoc } from "firebase/firestore". (The modular API is the recommended one and keeps the bundle smaller.)

### Questions
- Is Firebase free? The Spark plan is free with daily limits and needs no payment method; the Blaze plan adds more services and pay as you go.
- Is it safe that my Firebase key is in the web page? Yes, the Firebase web key only identifies your project; protection comes from Security Rules and App Check.
- Can I use Cloud Functions on the free plan? No. Functions are listed as not applicable on Spark; on Blaze the first 2 million invocations a month cost nothing.
- How big can one database record be? A Firestore document can be up to 1 MiB.
- Can my AI coding assistant work with my Firebase project? Yes. Firebase ships an MCP server that runs locally and works with Claude Code, Cursor and other assistants.

---
AgentGid's catalog is curated: every entry was checked against the maker's official pages (registry, repository, license and pricing pages) on the date shown; a license value shows the quote it stands on wherever AgentGid has one. Usage numbers come from AgentGid's own scan of public repositories set up for AI coding agents. Claims by makers are reported, not tested by AgentGid.
