Understand pricing

Click your Gemini API provider to view provider-specific content and code on this page.


Using Firebase AI Logic is free-of-charge. However, the costs for your Gemini API usage and whether your Firebase project needs to be on the pay-as-you-go Blaze pricing plan depends on your chosen Gemini API provider and the features of Firebase AI Logic that you use.

For the Agent Platform Gemini API (formerly Vertex AI):

  • Pricing is largely based on the model and features that you use.

This page provides a high-level overview of pricing and billing account requirements. For more details, see the Agent Platform Gemini API (formerly Vertex AI) pricing documentation.

Billing account requirements

To use the Agent Platform Gemini API (formerly Vertex AI), you must link your project to a Cloud Billing account. This means your Firebase project is upgraded to the pay-as-you-go Blaze pricing plan.

Here are some important key points about the Agent Platform Gemini API (formerly Vertex AI) and linking a Cloud Billing account:

  • All usage of the Agent Platform Gemini API (formerly Vertex AI) is pay-as-you-go
    Agent Platform Gemini API (formerly Vertex AI) always requires billing and all usage of the Agent Platform Gemini API (formerly Vertex AI) is pay-as-you-go pricing (including any usage through the Firebase AI Logic SDKs). Note that all Firebase and Google Cloud services (like Cloud Firestore) continue to offer their own specific no-cost usage levels.

  • Set up budget alerts and spend caps
    As part of linking a Cloud Billing account, we strongly recommend that you set up budget alerts and spend caps for the Agent Platform API.

    Note that the budgets you set for an API are not specific to usage of the API via Firebase AI Logic (for example, the budget applies if you use the API via a GenAI server SDK or Genkit in the same Google Cloud project).

Learn more about Agent Platform Gemini API (formerly Vertex AI) pricing in its documentation.

Other considerations for costs

If you're on the Blaze pricing plan, you might incur costs when you use other products in conjunction with Firebase AI Logic:

  • Other Firebase products may incur costs. For details, see the Firebase pricing page.

    • Using some of the attestation providers supported by Firebase App Check.
    • Using Cloud Storage for Firebase to send files in your multimodal requests beyond the no-cost usage levels.
    • Using Firebase Authentication beyond the no-cost usage levels.

    • Using any of Firebase's database products beyond their no-cost usage levels.

  • AI monitoring in the Firebase console may incur costs.
    While AI monitoring in the Firebase console is free-of-charge itself, you may incur costs if you go beyond the no-cost usage levels of the underlying Google Cloud Observability Suite products. Learn more in the Google Cloud Observability Suite pricing documentation.

Recommendations to manage costs

We recommend doing the following to help manage your costs: