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 Gemini Developer API:

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

  • Using some models (especially preview models and image-generating models) might require billing.

This page provides a high-level overview of pricing and billing account requirements. For more details, see the Gemini Developer API pricing documentation and billing FAQ.

Billing account requirements

The Gemini Developer API offers different tiers for its pricing. The following sections provide a high-level overview of these tiers, but review their details in the Gemini Developer API pricing documentation.

Gemini Developer API "free tier"

The Gemini Developer API "free tier" lets you get started without having to provide a payment method. It gives you limited access to certain models and access to many basic features.

To use this "free tier", you do not link your project to a Cloud Billing account. This means your Firebase project is on the no-cost Spark pricing plan.

Gemini Developer API "paid tiers"

The Gemini Developer API "paid tiers" are available when you require higher volumes or want access to more models or advanced features.

To use these "paid tiers", 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.

Learn more about billing setup and payments in the Gemini Developer API billing 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 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: