Firebase FAQ (original) (raw)

The page is a collection of FAQs and troubleshooting help for Firebase in general, as well as for specific products.

Do you have other challenges or can't find your issue described on this page?


Platforms and frameworks

Visit the platform-specific troubleshooting & FAQ pages for helpful tips and answers for more FAQ.


Firebase projects and Firebase apps

What is a Firebase project?

A Firebase project is the top-level entity for Firebase. In a project, you can register your Apple, Android, or web apps. After you register your apps with Firebase, you can add theproduct-specific Firebase SDKs to your app, likeAnalytics, Cloud Firestore, Crashlytics, or Remote Config.

You should register your Apple, Android, and web app variants within a single Firebase project. You can use multiple Firebase projects to support multiple environments, such as development, staging, and production.

Here are some resources for learning more about Firebase projects:

Note that for all Firebase projects, Firebase automatically adds a label offirebase:enabled within theLabels page for your project in theGoogle Cloud console. Learn more about this label in ourFAQ.

What is a Google Cloud organization?

A Google Cloud organization is a container for Google Cloud projects (including Firebase projects). This hierarchy enables better organization, access management, and auditing of your Google Cloud and Firebase projects. For more information, refer toCreating and Managing Organizations.

How does Firebase's integration with Google Cloud work?

Firebase is deeply integrated withGoogle Cloud. Projects are shared between Firebase and Google Cloud, so projects can have Firebase services and Google Cloud services enabled. You can access the same project from the Firebase console or the Google Cloud console. Specifically:

In addition, when you upgrade to the pay-as-you-go Blaze pricing plan, you can use any of Google Cloud's world-class Infrastructure-as-a-Service and APIs directly inside your Firebase project, at standardGoogle Cloud pricing. You can also export data from Google Cloud directly toBigQuery for analysis. To learn more, seeLink BigQuery with Firebase.

There are many security-enhancing, latency-improving, and time-saving benefits to using Google Cloud with Firebase (versus other, cloud services that are not co-located). Check out theGoogle Cloud site for more details.

Why does my Google Cloud project have a label offirebase:enabled?

In theLabels page for your project in the Google Cloud console, you may see a label offirebase:enabled (specifically, a Key offirebase with a Value of enabled).

Firebase automatically added this label because your project is a Firebase project, which means that your project has Firebase-specific configurations and services enabled for it. Learn more about therelationship between Firebase projects and Google Cloud.

We strongly recommend that you don't modify or delete this label. This label is used by Firebase and Google Cloud to list your Firebase projects (for example, using theREST APIprojects.list endpoint or in menus within the Firebase console).

Be aware that manually adding this label to your list of project labels does NOT enable Firebase-specific configurations and services for yourGoogle Cloud project. To do that, you need to add Firebase using theFirebase console (or, for advanced use cases, using theFirebase Management REST API or theFirebase CLI).

Why isn't my Firebase project showing up in my list of Firebase projects?

This FAQ is applicable if you don't see your Firebase project in the following places:

Try these troubleshooting steps:

  1. First, try accessing your project by visiting the project's URL directly. Use the following format:
    **https://console.firebase.google.com/project/PROJECT-ID/overview**
  2. If you can't access the project or receive permissions errors, check the following:
    • Make sure that you're signed into Firebase using the same Google Account that has access to the project. You can sign in and out of the Firebase console via your account avatar in the top-right corner of the console.
    • Check if you can view the project in theGoogle Cloud console.
    • Make sure that your project has the labelfirebase:enabled in theLabels page for your project in theGoogle Cloud console. Firebase and Google Cloud use this label to list your Firebase projects. If you don't see this label but_the Firebase Management API is enabled_ for your project, then manually add the label (specifically, a Key offirebase with a Value ofenabled).
    • Make sure that you're assigned one of thebasic IAM roles (Owner, Editor, Viewer) or a role that has Firebase-related permissions in it, for example aFirebase predefined role. You can view your role(s) in theIAM page of the Google Cloud console.
    • If your project belongs to a Google Cloud organization, you may require additional permissions to see the project listed in theFirebase console. Contact the person who manages your Google Cloud organization to give you the appropriate role to view the project, for example the Browser role.

If none of the troubleshooting steps above enable you to see your project in a list of Firebase projects, contactFirebase Support.

How many projects can I have per Google Account (email address)?

Note the following about the limit on project-creation quota:

Learn about Firebase's recommendedgeneral best practices for setting up Firebase projects.

How many Firebase Apps can I have in a Firebase project?

A Firebase project is a container for Firebase Apps across Apple, Android, and web. Firebase restricts the total number of Firebase Apps within a Firebase project to 30.

After this number, performance starts to degrade (especially forGoogle Analytics) and eventually, at a higher number of apps, some product functionality stops working. Additionally, if you use Google sign-in as an authentication provider, an underlying OAuth 2.0 client ID is created for each app in your project. There's a limit of around 30 client IDs that can be created within a single project.

You should ensure that all Firebase Apps within a single Firebase project are platform variants of the same application from an end-user perspective. For example, if you develop a white-label application, each independently labeled app should have its own Firebase project, but the Apple and Android versions of that label can be in the same project. Read more detailed guidance in ourgeneral best practices for setting up Firebase projects.

In the rare case your project requires more than 30 apps, you can request an app limit increase. Your project must be on the Blaze pricing plan to make this request. Visit theGoogle Cloud console tomake your request and have it evaluated. Learn more aboutquota management in the Google Cloud documentation.

What happens if I tag my project as a "production" environment?

In the Firebase console, you can tag your Firebase projects with their environment type, either as Production or Unspecified (non-prod) environments.

Tagging your project as an environment type has no effect on how your Firebase project works or its features. However, the tagging can help you and your team manage your various Firebase projects for the app lifecycle.

If you tag your project as a production environment, we add a brightly colored Prod tag to the project in the Firebase console, reminding you that any changes could affect your associated production apps. In the future, we might add more features and safeguards for Firebase projects tagged as production environments.

To change the environment type of your Firebase project, go to Project settings > General, then in the Your project card under Environment, click to change the environment type.

Where can I find the App ID for my Firebase app?

In the Firebase console, go to your Project settings. Scroll down to the_Your apps_ card, then click on the desired Firebase App to view the app's information, including its App ID.

Here are some example App ID values:

What are the prerequisites for linkingGoogle Play / AdMob / Google Ads / BigQuery to my Firebase project or app?

Permissions and access to Firebase projects

How do I assign a project member a role, like the Owner role?

To manage the role(s) assigned to each project member, you must be an Owner of the Firebase project (or be assigned a role with the permissionresourcemanager.projects.setIamPolicy).

Here are the places where you can assign and manage roles:

If the Owner of your project can no longer perform the tasks of an Owner (for example, the person left your company) and your project isn't managed via a Google Cloud organization (see next paragraph), you cancontact Firebase Support and check with them about how to request access to the Firebase project.

Note that if a Firebase project is part of a Google Cloud organization, it may not have an Owner. If you're unable to find an Owner for your Firebase project, contact the person who manages yourGoogle Cloud organization to assign an Owner for the project.

How do I find the Owner of a Firebase project?

You can view project members and their roles in the following places:

If the Owner of your project can no longer perform the tasks of an Owner (for example, the person left your company) and your project isn't managed via a Google Cloud organization (see next paragraph), you cancontact Firebase Support to have a temporary Owner assigned.

Note that if a Firebase project is part of a Google Cloud organization, it may not have an Owner. Instead, the person who manages your Google Cloud organization can perform many tasks that an Owner can do. However, to perform several Owner-specific tasks (like assigning roles or managingGoogle Analytics properties), the administrator may need to assign themselves theactual Owner role to perform those tasks. If you're unable to find an Owner for your Firebase project, contact the person who manages your Google Cloud organization to assign an Owner for the project.

Why or when should I assign a project member the Owner role?

To ensure proper management of a Firebase project, it must have anOwner.

Project members with the Owner role areoften the only project members who can do administrative tasks or receive important notifications:

After you set up the Owner(s) for a Firebase project, it's important to keep those assignments up-to-date.

Note that if a Firebase project is part of a Google Cloud organization, the person who manages your Google Cloud organization can perform many tasks that an Owner can do. However, for several Owner-specific tasks (like assigning roles or managing Google Analytics properties), the administrator may need to assign themselves theactual Owner role to perform those tasks.

I don't think that I have a Firebase project, but I got an email about one. How do I access this project?

The email you received should contain a link to open your Firebase project. Clicking the link in the email should open the project in theFirebase console.

If you're not able to open the project in the link, make sure that you're signed into Firebase using the same Google Account that received the email about the project. You can sign in and out of the Firebase console via your account avatar in the top-right corner of the console.

Note that if you're the administrator of a Google Cloud organization, you may be notified about changes to Firebase projects inside your organization. However, you may not have sufficient permissions to open the Firebase project. In these cases, the simplest solution is to assign yourself theactual Owner role to open the project and perform the required actions. Learn more aboutwhy and when to assign the Owner role.

API keys for Firebase

Are Firebase API keys secret? Can they be included in my code or configuration files?

Here are the most important things to learn about API keys for Firebase services:

If your app's setup follows the above guidelines, then_API keys restricted to Firebase services_ do not need to be treated as secrets, and it's safe to include them in your code or configuration files.

I received an email from Google Cloud about a "publicly accessible Google API key for your Google Cloud project". What do I need to do?

If you've received an email from Google Cloud about a "publicly accessible Google API key for your Google Cloud project" and the API key listed in the email is your Firebase API key, then make sure that the API key meets the following requirements to be safe to include in your code or configuration files. You can verify the following in theAPIs & Services > Credentials panel in the Google Cloud console.

Also, make sure that you're using Firebase Security Rules and App Check as recommended for the Firebase products that you use.

You can learn details about API keys for Firebase and find a list of FAQs inLearn about using and managing API keys for Firebase


Firebase console

What are the supported browsers for accessing the Firebase console?

The Firebase console can be accessed from recent versions of popular desktop browsers such as Chrome, Firefox, Safari and Edge. Mobile browsers are not fully supported.

I can load the Firebase console, but why can't I find or access my Firebase project?

This FAQ is applicable if you're experiencing either of the following issues:

Try these troubleshooting steps:

  1. First, try accessing your project by visiting the project's URL directly. Use the following format:
    **https://console.firebase.google.com/project/PROJECT-ID/overview**
  2. If you still can't access the project or receive permissions errors, check the following:
    • Make sure that you're signed into Firebase using the same Google Account that has access to the project. You can sign in and out of the Firebase console via your account avatar in the top-right corner of the console.
    • Make sure that theFirebase Management API is enabled for the project.
    • Make sure that you're assigned one of thebasic IAM roles (Owner, Editor, Viewer) or a role that has Firebase-related permissions in it, for example aFirebase predefined role. You can view your role(s) in theIAM page of the Google Cloud console.
    • If your project belongs to a Google Cloud organization, you may require additional permissions to see the project listed in theFirebase console. Contact the person who manages your Google Cloud organization to give you the appropriate role to view the project, for example the Browser role.

If none of the troubleshooting steps above enable you to find or access your project, contactFirebase Support.

Why is the Firebase console not loading for me?

This FAQ is applicable if you're experiencing any of the following issues:

Try these troubleshooting steps:

  1. Check the Console row of theFirebase Status Dashboard for any possible service interruptions.
  2. Make sure that you're using asupported browser.
  3. Try to load the Firebase console in an incognito or private window.
  4. Disable all browser extensions.
  5. Verify that the network connection is not blocked by ad blocker, antivirus, proxy, firewall, or other software.
  6. Try loading the Firebase console using a different network or device.
  7. If using Chrome, check theDeveloper Tools Console for anyerrors.

If none of the troubleshooting steps above resolve the issue, contactFirebase Support.

How is my Firebase console language determined?

The language setting for the Firebase console is based on the language selected in yourGoogle Account settings.

To change your language preference, seeChange language.

The Firebase console supports the following languages:

What roles and permissions does the Firebase console support?

The Firebase console and Google Cloud console use the same underlying roles and permissions. Learn more about roles and permissions in the Firebase IAM documentation.

Firebase supports thefundamental (basic) roles of Owner, Editor, and Viewer:

Firebase also supports:

How does the console's "sample app experience" work? What happens and what can I do?

The Firebase console provides asample app experienceso that you have a real working app to explore and experiment with Firebase and other Google services (like the Gemini API).

Automatic Firebase setup and deployment of the sample app

When you go through thesample app experiencein the Firebase console, we automatically do the following for you:

Explore the sample app's codebase

Firebase Local Emulator Suite

This message means the Local Emulator Suite has detected it may be running a particular product emulator using different project IDs. This may indicate a misconfiguration, and can cause issues when emulators try to communicate with one another, and when you try to interact with emulators from your code. If project IDs don't match, it often appears that data is missing, since data stored in emulators is keyed to projectID, and interoperability depends on matching project IDs.

This has been a common source of confusion among developers, so by default the Local Emulator Suite will now only allow running with a single project ID, unless you specify otherwise in thefirebase.json configuration file. If an emulator detects more than one project ID, it will log a warning and potentially throw a fatal error.

Check your project ID declaration(s) for mismatches in:

Platform-specific places to check:

Web The projectId property in your JavaScriptfirebaseConfig object, used ininitializeApp.
Android The project_id property inside thegoogle-services.json configuration file.
Apple platforms The PROJECT_ID property in theGoogleService-Info.plist configuration file.

To disable single project mode, update firebase.json with thesingleProjectMode key:

{ "firestore": { ... }, "functions": { ... }, "hosting": { ... }, "emulators": { "singleProjectMode": false, "auth": { "port": 9099 }, "functions": { "port": 5001 }, ... } }


Pricing

For pricing FAQs specific to a product, see the product's section on this page or within its dedicated product documentation.

Which products are paid? Which are no-cost?

For detailed information about paid versus no-cost products, seeFirebase pricing plans.

Does Firebase offer no-cost trial credits for paid products?

Firebase paid services can be used under theGoogle Cloud Free Trial. New Google Cloud and Firebase users can take advantage of a 90-day trial period that includes $300 in free Cloud Billing credits to explore and evaluateGoogle Cloud and Firebase products and services.

During the Google Cloud Free Trial period, you'll be provided a Free TrialCloud Billing account. Any Firebase project that's linked to that billing account will be on the pay-as-you-go Blaze pricing plan during the Free Trial period.

Don't worry, linking a Firebase project to this Free Trial Cloud Billing account does not enable us to charge you for usage beyond these credits. You are not charged for usage beyond these credits unless you explicitly enable billing by upgrading your Free Trial Cloud Billing account to a paid account. You can upgrade to a paid account at any time during the trial. After you've upgraded to a paid account, you can still use any remaining credits (within the 90-day period).

Once the free trial expires and if you have not upgraded the Free Trial Cloud Billing account to a paid account, then your linked Firebase project is automaticallydowngraded to the Spark pricing plan. Note that you canupgrade to the Blaze pricing planagain at any time.

Learn more about theGoogle Cloud Free Trial.

How do I know which pricing plan is right for me?

For detailed information about pricing plans, seeFirebase pricing plans.

Spark pricing plan

The no-cost Spark pricing plan is a great place to develop your app at no cost. You get all the no-cost Firebase products (like Analytics,Remote Config, Crashlytics, and so on) and generous amounts of our paid infrastructure features. However, if you exceed your Spark pricing plan resources in a calendar month, your app will be shut off for the remainder of that month. In addition, Google Cloud features are not available when using the Spark pricing plan.

Blaze pricing plan

The pay-as-you-go Blaze pricing plan is designed for production apps. The Blaze pricing plan also lets you extend your app with paidGoogle Cloud features. You pay only for the resources that you consume, allowing you to scale with demand. We strive to make our Blaze pricing plan prices competitive with industry-leading cloud providers.

Can I upgrade, downgrade, or cancel at any time?

Yes, you can upgrade, downgrade, or cancel at any time. Note that we don't provide prorated refunds for downgrades or cancellations. This means that if you downgrade or cancel before the end of your billing period, you still pay for the remainder of the month.

How is the no-cost usage in the Blaze pricing plan different from the no-cost usage in the Spark pricing plan?

No-cost usage on the Blaze pricing plan is calculated daily. Usage limits also differ from the Spark pricing plan forCloud Functions, phone authentication, and Test Lab.

For Cloud Functions, no-cost usage on the Blaze pricing plan is calculated at the Cloud Billing account level, not the project level and has the following limits:

For phone authentication, no-cost usage on the Blaze pricing plan is calculated monthly.

For Test Lab, no-cost usage on the Blaze pricing plan has the following limits:

Does the no-cost usage quota reset when I change from the Spark pricing plan to the Blaze pricing plan?

No-cost usage from the Spark pricing plan is included in the Blaze pricing plan. No-cost usage does not reset when moving to the Blaze pricing plan.

If a Cloud Billing account is linked to a project in theGoogle Cloud console, the same project will automatically be upgraded to the Firebase pay-as-you-go Blaze pricing plan (if that project was on the no-cost Spark pricing plan).

In contrast, if an existing active Cloud Billing account is unlinked from a project in the Google Cloud console, that project will be downgraded to the Firebase no-cost Spark pricing plan.

Can I cap usage on the Blaze pricing plan?

No, you cannot cap your usage on the Blaze pricing plan. However, we are actively evaluating options for supporting caps on usage when on the Blaze pricing plan.

If your project is on the Blaze pricing plan, you can define a budget for your project or account, and receive alerts as spending approaches those limits. Learn how toset up budget alerts.

What kind of support will I receive?

All Firebase apps, including those using no-cost plans, come with email support from Firebase staff during US Pacific business hours. All accounts have unlimited support for billing-related issues, account-related issues, technical (troubleshooting) questions, and incident reports.

Do you offer open-source, nonprofit, or educational discounts?

The no-cost Spark pricing plan can be used by any type of individual or organization, including nonprofits, schools, and open-source projects. Since these plans already include generous quotas, we don't offer any special discounts or plans for open-source, nonprofit, or educational projects.

Do you offer enterprise contracts, pricing, support, or dedicated infrastructure hosting?

The pay-as-you-go Blaze pricing plan is suitable for enterprises of all sizes, and ourSLA meets or exceeds the industry standard for cloud infrastructure. However, we don't offer enterprise contracts, pricing, or support, nor do we offer dedicated infrastructure hosting (that is, on-premises installations) for services like our Realtime Database. However, we're actively investigating options for adding some of these features.

Do you offer ad hoc pricing? I only want pay-as-you-go for one or two features.

We offer ad hoc pricing via the pay-as-you-go Blaze pricing plan, where you pay only for the features that you use.

How do the paid Firebase plans work with Ads? Are there no-cost advertising credits with paid plans?

The Firebase pricing plans are separate from Ads, so there are no advertising credits without cost. As a Firebase developer, you are able to "link" your Ads account to Firebase to support conversion tracking.

All ads campaigns are managed directly in Ads, andAds billing is managed from the Ads console.

What happened to the Flame pricing plan?

In January 2020, the Flame pricing plan ($25/mo of additional quota) was removed as an option for new sign-ups. Existing plan users were granted a grace period to migrate their projects off the Flame plan. In February 2022, the remaining projects on the Flame pricing plan were downgraded to the no-cost Spark pricing plan.
Accordingly,

Do you have more questions about the Flame plan retirement? Read some of theadditional FAQs below.

Want to learn about the other pricing plans offered by Firebase? Visit ourFirebase pricing page. If you'd like to start moving any existing projects to another pricing plan, you can do that in theFirebase console for your project.

Additional FAQs about the Flame plan retirement

I have a project or a process or a business model that relies on a fixed Firebase cost. What should I do?

Sign up for the Blaze pricing plan, and make sure toset budget alerts.

May I be given special access to create new Flame plan projects?

No, Firebase isn't offering special access for projects to switch to or sign-up for the Flame plan.

I changed my Flame plan project to a different pricing plan. How do I change it back?

Switching to the Flame plan is no longer possible. For access to services provided by the Flame plan, make sure that you're using the Blaze pricing plan, and considersetting up budget alerts for your project.

My project was automatically switched to a different pricing plan as part of the Flame plan retirement. What should I do?

If your project requires additional quota beyond what is provided with the Spark pricing plan, you'll need to upgrade your project to the Blaze pricing plan.

Why is the Flame plan being retired?

Over the years, we've seen declining usage of the Flame plan, and most projects that use the plan are not consuming its full value. Maintaining this pricing plan is generally not cost-effective, and we feel that we can serve everyone better if resources went to other Firebase initiatives.


Privacy

Do the Firebase SDKs log any usage/diagnostic information outside of Analytics?

Yes. Right now, this is iOS-only, but may change in the future. The Firebase Apple platforms SDK includes the FirebaseCoreDiagnostics framework by default. This framework is used by Firebase to collect SDK usage and diagnostics information to help prioritize future product enhancements. FirebaseCoreDiagnostics is optional, so if you would like to opt out of sending Firebase diagnostic logs, you can do so by unlinking the library from your application. You can browse the full source, including logged values, onGitHub


A/B Testing

Visit theA/B Testing troubleshooting & FAQ pagefor helpful tips and answers to more FAQs.


AdMob

No, Windows apps are not supported.

You can link an AdMob app to a Firebase app via the AdMob console.Learn how.

In order to do this linking, you need the following access:

Formulti-user AdMob accounts, the user who created the first Firebase link and accepted theFirebase Terms of Service is the only user who can create new links between AdMob apps and Firebase apps.

AdMob: To use AdMob, which SDKs should I use?

To use AdMob, always use the Google Mobile Ads SDK as described in this FAQ. Additionally and optionally, if you want to collect user metrics for AdMob, then include the Firebase SDK for Google Analytics in your app.


Analytics

Google Analytics is a no-cost and unlimited analytics solution that works with Firebase features to deliver powerful insights. It lets you view event logs in Crashlytics, notification effectiveness inFCM, deep link performance for Dynamic Links, and in-app purchase data from Google Play. It powers advanced audience targeting inRemote Config, Remote Config personalization, and more.

Google Analytics acts as a layer of intelligence in theFirebase console to provide you with more actionable insights about how to develop a high quality app, grow your user base, and earn more money.

To get started,read the documentation.

Analytics: How do I control how my Analytics data is shared with the rest of Firebase?

By default, your Google Analytics data is used to enhance other Firebase and Google features. You can control how yourGoogle Analytics data is shared in your project settings anytime. Learn more aboutData sharing settings.

Analytics: How do I update my Analytics property settings?

From the Admin page in your Google Analytics property, you can update your property settings, such as:

To update your property settings, follow these steps:

  1. In the Firebase console, go to your >Project settings.
  2. Go to the Integrations tab, and then in the Google Analytics card, click Manage or View link.
  3. Click the link for your Google Analytics account toopen the account and property settings.
Analytics on-device measurement in my iOS app: How was the Analytics SDK updated for on-device conversion measurement support, and am I required to upgrade?

Before our release updating on-device conversion measurement using event data, developers had to manually include multiple SDK modules to use on-device measurement capabilities, a time-consuming process. As a result, we updated the existing default SDK module (FirebaseAnalytics) to include on-device conversion measurement capabilities as well forGoogle Ads.

If you install the default Google Analytics for Firebase iOS SDK, your app can also benefit fromon-device conversion measurement capabilities.

If you've pinned the SDK to a specific version, update to version 11.14.0 or higher and release a new version of your app.

Target Capabilities Old module(s) (SDK versions < 11.14.0) New module(s) (SDK versions >= 11.14.0)
Analytics IDFA On-Device Conversion Measurement (First-Party Data) On-Device Conversion Measurement (Event Data) N/A FirebaseAnalytics
Analytics IDFA FirebaseAnalytics FirebaseAnalytics/Core FirebaseAnalytics/IdentitySupport
Analytics FirebaseAnalytics/WithoutAdIdSupport (deprecated) FirebaseAnalytics/Core
Analytics On-Device Conversion Measurement (First-Party Data) FirebaseAnalytics/WithoutAdIdSupport (deprecated) FirebaseAnalyticsOnDeviceConversion (deprecated) FirebaseAnalytics/Core GoogleAdsOnDeviceConversion*
Analytics On-Device Conversion Measurement (Event Data) N/A FirebaseAnalytics/Core GoogleAdsOnDeviceConversion
Analytics On-Device Conversion Measurement (First-Party Data) On-Device Conversion Measurement (Event Data) N/A FirebaseAnalytics/Core GoogleAdsOnDeviceConversion
Analytics IDFA On-Device Conversion Measurement (First-Party Data) FirebaseAnalytics FirebaseAnalyticsOnDeviceConversion (deprecated) FirebaseAnalytics*
Analytics IDFA On-Device Conversion Measurement (Event Data) N/A FirebaseAnalytics

* This configuration will include On-Device Conversion Measurement (Event Data) as well. If needed, you can disable the feature by setting the value of GOOGLE_ADS_ON_DEVICE_CONVERSION_EVENT_DATA_ENABLED toNO (Boolean) in your app's Info.plist file.

Analytics in my iOS app: How do I enable the AdSupport framework?

Some Analytics features, such as audiences and campaign attribution, and some user properties, such as age and interests, require theAdSupport frameworkto be enabled. Without this framework, Analytics cannot collect information needed for these features to function properly.

To enable the AdSupport framework:

  1. In your Xcode project, select your project's target.
  2. Select the General tab for your target.
  3. Expand the Linked Frameworks and Libraries section.
  4. Click + to add a framework.
  5. Select AdSupport.framework.
  6. Add the -ObjC linker flag to your project's build settings underOther Linker Flags.

Before submitting your app for review, ensure your app complies withIDFA usage guidelines.

Analytics: Why don't I see any Analytics data in the Firebase console after unlinking Firebase from Google Analytics?

Analytics data resides within the Google Analytics property — not within the Firebase project. If you delete or unlink the property, then theAnalytics data won't be accessible to Firebase and you'll see an empty Analytics dashboard in the Firebase console. Note that since the data still resides in the previously linked property, you can always relink the property to Firebase and see the Analytics data in theFirebase console.

Linking a brand new Google Analytics account (and thus a new Google Analytics property) to your Firebase project will result in an empty_Analytics_ dashboard in the Firebase console. However, if your previously linked property still exists, then you can move the existing data from the old property to the new property.

Analytics: If my Analytics property and its data were deleted, is there any way to get them back?

No. If your property has been deleted, it isn't possible to undelete the property or retrieve the previously collected Analytics data stored in that property.

If you'd like to start using Google Analytics again, you can link either a new property or an existing property to your Firebase project. You can do this linking in either the Firebase console or the Google Analytics UI. Learn more aboutlinking a Google Analytics property to your Firebase project.

If you'd like to start using Google Analytics again, you can link either a new property or an existing property to your Firebase project. You can do this linking in either the Firebase console or the Google Analytics UI. Learn more aboutlinking a Google Analytics property to your Firebase project.

Note that since all Analytics data is stored in the property (not the Firebase project), the previously collected Analytics data cannot be retrieved.

Analytics: How will Firebase products or integrated Google products be affected by the deletion of my Analytics property?

Several Firebase products rely on the Google Analytics integration. If your Analytics property and its data are deleted, the following will happen if you use the following products:

In addition, the following integrations will be affected:

Analytics: Can I move Analytics data from one Firebase project to another project?

No, it isn't possible to directly move Analytics data from one Firebase project to another project. However, you can export and combine data from both projects into a single location, such asBigQuery for analysis.

While moving existing data isn't possible, you can link an existingAnalytics property to a new Firebase project and start collecting data from then on in that new project. You can do this linking in either theFirebase console or the Google Analytics UI. Learn more aboutlinking a property to your Firebase project.

Analytics: How do I segment users who have_not_ met some criterion?

You can reframe the problem by "negatively targeting" these users. For example, reframe the problem as "Don't show ads to people who have bought something", and form anaudience of those users to target.

Analytics: Are audiences and/or events defined in the Google Analytics interface also available in the Firebase console?

Your audiences and user properties will be synced. For some features, you'll need to use the Google Analytics interface, such as segmentation and closed funnels. You can access the Google Analytics interface directly via deep-links from the Firebase console.

Any changes you make from the Firebase console can also be performed in Google Analytics, and those changes will be reflected in Firebase.


Authentication

Authentication: Which regions are supported for phone authentication?

Firebase Authentication supports phone number verification globally, but not all networks reliably deliver verification messages. The following regions have good rates of delivery, and should be expected to work well for phone authentication. Where noted, some carriers are unavailable in a region due to poor delivery success rates.

Region Code
AD Andorra
AE United Arab Emirates
AF Afghanistan
AG Antigua and Barbuda
AL Albania
AM Armenia
AO Angola
AR Argentina
AS American Samoa
AT Austria
AU Australia
AW Aruba
AZ Azerbaijan
BA Bosnia and Herzegovina
BB Barbados
BD Bangladesh
BE Belgium
BF Burkina Faso
BG Bulgaria
BJ Benin
BM Bermuda
BN Brunei Darussalam
BO Bolivia
BR Brazil
BS Bahamas
BT Bhutan
BW Botswana
BY Belarus
BZ Belize
CA Canada
CD Congo, (Kinshasa)
CF Central African Republic
CG Congo (Brazzaville)
CH Switzerland
CI Côte d'Ivoire
CK Cook Islands
CL Chile
CM Cameroon
CO Colombia
CR Costa Rica
CV Cape Verde
CW Curaçao
CY Cyprus
CZ Czech Republic
DE Germany
DJ Djibouti
DK Denmark
DM Dominica
DO Dominican Republic
DZ Algeria
EC Ecuador
EG Egypt
ES Spain
ET Ethiopia
FI Finland
FJ Fiji
FK Falkland Islands (Malvinas)
FM Micronesia, Federated States of
FO Faroe Islands
FR France
GA Gabon
GB United Kingdom
GD Grenada
GE Georgia
GF French Guiana
GG Guernsey
GH Ghana
GI Gibraltar
GL Greenland
GM Gambia
GP Guadeloupe
GQ Equatorial Guinea
GR Greece
GT Guatemala
GY Guyana
HK Hong Kong, SAR China
HN Honduras
HR Croatia
HT Haiti
HU Hungary
ID Indonesia
IE Ireland
IL Israel
IM Isle of Man
IN India
IQ Iraq
IT Italy
JE Jersey
JM Jamaica
JO Jordan
JP Japan
KE Kenya
KG Kyrgyzstan
KH Cambodia
KM Comoros
KN Saint Kitts and Nevis
KR Korea (South)
KW Kuwait
KY Cayman Islands
KZ Kazakhstan
LA Lao PDR
LB Lebanon
LC Saint Lucia
LI Liechtenstein
LK Sri Lanka
LS Lesotho
LT Lithuania
LU Luxembourg
LV Latvia
LY Libya
MA Morocco
MD Moldova
ME Montenegro
MF Saint-Martin (French part)
MG Madagascar
MK Macedonia, Republic of
MM Myanmar
MN Mongolia
MO Macao, SAR China
MS Montserrat
MT Malta
MU Mauritius
MW Malawi
MX Mexico
MY Malaysia
MZ Mozambique
NA Namibia
NC New Caledonia
NE Niger
NF Norfolk Island
NG Nigeria
NI Nicaragua
NL Netherlands
NO Norway
NP Nepal
NZ New Zealand
OM Oman
PA Panama
PE Peru
PG Papua New Guinea
PH Philippines
PK Pakistan
PL Poland
PM Saint Pierre and Miquelon
PR Puerto Rico
PS Palestinian Territory
PT Portugal
PY Paraguay
QA Qatar
RE Réunion
RO Romania
RS Serbia
RU Russian Federation
RW Rwanda
SA Saudi Arabia
SC Seychelles
SE Sweden
SG Singapore
SH Saint Helena
SI Slovenia
SK Slovakia
SL Sierra Leone
SN Senegal
SR Suriname
ST Sao Tome and Principe
SV El Salvador
SZ Swaziland
TC Turks and Caicos Islands
TG Togo
TH Thailand
TL Timor-Leste
TM Turkmenistan
TO Tonga
TR Turkey
TT Trinidad and Tobago
TW Taiwan, Republic of China
TZ Tanzania, United Republic of
UA Ukraine
UG Uganda
US United States of America
UY Uruguay
UZ Uzbekistan
VC Saint Vincent and Grenadines
VE Venezuela (Bolivarian Republic)
VG British Virgin Islands
VI Virgin Islands, US
VN Viet Nam
WS Samoa
YE Yemen
YT Mayotte
ZA South Africa
ZM Zambia
ZW Zimbabwe
Authentication: What happened to the no-cost SMS on the Spark pricing plan?

Starting September 2024, to improve the security and service quality of Phone Authentication, Firebase projects must be linked to aCloud Billing account to enable and use the SMS Service.

Authentication: How can I prevent SMS abuse when using phone authentication?

To help protect your project from SMS traffic pumping and API abuse, take the following steps:

Consider setting an SMS region policy
  1. View your regional SMS usage.
    Look for regions with a very high number of sent SMS and a very low number (or zero) of verified SMS. The ratio of verified/sent is your success rate. Healthy success rates are commonly in the 70-85% range since SMS is not a guaranteed delivery protocol, and some regions may experience abuse. Success rates lower than 50% imply many sent SMS but few successful logins, which is a common indicator of bad actors and SMS traffic pumping.
  2. UseSMS Region Policyto either deny SMS regions with low success rates, or only allow certain regions if your app is only intended for distribution in certain markets.

Use theAuthentication settings dashboardto manage authorized domains. The localhost domain is added by default to the approved authentication domains to simplify development. Consider removinglocalhost from the authorized domains in your production project to prevent bad actors from running code on their localhost to access your production project.

Enable and enforce App Check

Enable App Check to help protect your project from API abuse by attesting that requests only come from applications associated with your project.

To use App Check with Firebase Authentication, you must upgrade toFirebase Authentication with Identity Platform.

Remember that you need to enforce App Check for Authentication in theFirebase console(consider monitoring traffic before enforcing). Also, double check yourreCAPTCHA Enterpriseapproved sites list to validate that it only contains your production sites, and that the list of applications registered to your project in App Check is accurate.

Note that App Check helps protect against automated attacks by asserting that the call comes from one of your registered applications. It does not prevent users from using your app in unintended ways (for example, starting then never finishing login flows to generate sent SMS).

Authentication: Are phone numbers ported to a new carrier supported by phone authentication?

At this time, numbers ported between carriers will result in all SMS becoming undeliverable for those end users. There is no workaround, and Firebase is working on this issue.

Authentication: In my Android app, why am I getting the following error:

Google sign in failed?

Follow the troubleshooting steps in this FAQ if you're getting the following error:

GoogleFragment: Google sign in failed
    com.google.android.gms.common.api.ApiException: 13: Unable to get token.
        at
com.google.android.gms.internal.auth-api.zbay.getSignInCredentialFromIntent(com.google.android.gms:play-services-auth@@20.3.0:6)
  1. Make sure that Google sign-in is properly enabled as an authentication provider:
    1. In the Firebase console, open theAuthentication section.
    2. Within the Sign in method tab, disable and then re-enable theGoogle sign-in method (even if it's already enabled):
      1. Open the Google sign-in method, disable it, and then clickSave.
      2. Re-open the Google sign-in method, enable it, and then clickSave.
  2. Make sure that your app is using its up-to-date Firebase configuration file (google-services.json).
    Obtain your app's config file.
  3. Check if you're still getting the error. If you are, continue to the next troubleshooting step.
  4. Make sure the required underlying OAuth 2.0 clients are present.
    1. In the Credentialspage of the Google Cloud console, look in the OAuth 2.0 Client IDssection.
    2. If OAuth 2.0 clients are not present (and you've done all the troubleshooting steps above), thencontact Support.
Authentication: In my Apple platform app, why am I getting the following error:

You must specify <clientID> in <GIDConfiguration>?

Follow the troubleshooting steps in this FAQ if you're getting the following error:

You must specify |clientID| in |GIDConfiguration|
  1. Make sure that Google sign-in is properly enabled as an authentication provider:
    1. In the Firebase console, open theAuthentication section.
    2. Within the Sign in method tab, disable and then re-enable theGoogle sign-in method (even if it's already enabled):
      1. Open the Google sign-in method, disable it, and then clickSave.
      2. Re-open the Google sign-in method, enable it, and then clickSave.
  2. Make sure that your app is using its up-to-date Firebase configuration file (GoogleService-Info.plist).
    Obtain your app's config file.
  3. Check if you're still getting the error. If you are, continue to the next troubleshooting step.
  4. Make sure the required underlying OAuth 2.0 clients are present.
    1. In the Credentialspage of the Google Cloud console, look in the OAuth 2.0 Client IDssection.
    2. If OAuth 2.0 clients are not present (and you've done all the troubleshooting steps above), thencontact Support.
Authentication: In my web app, why am I getting the following error:

AuthErrorCode.INVALID_OAUTH_CLIENT_ID?

Follow the troubleshooting steps in this FAQ if you're getting the following error:

AuthErrorCode.INVALID_OAUTH_CLIENT_ID
  1. Make sure that Google sign-in is properly enabled as an authentication provider:
    1. In the Firebase console, open theAuthentication section.
    2. Within the Sign in method tab, disable and then re-enable theGoogle sign-in method (even if it's already enabled):
      1. Open the Google sign-in method, disable it, and then clickSave.
      2. Re-open the Google sign-in method, enable it, and then clickSave.
  2. Also, in the Google sign-in provider configuration of the Authenticationsection, make sure that the OAuth client ID and secret match the web client displayed in theCredentialspage of the Google Cloud console (look in the OAuth 2.0 Client IDssection).
Authentication: In my web app, why are sign-in with redirects failing with the following error:

This domain YOUR_REDIRECT_DOMAIN is not authorized to run this operation?

Follow the troubleshooting steps in this FAQ if you're getting the following error:

This domain YOUR_REDIRECT_DOMAIN is not authorized to run this operation.

This error is most likely caused because your redirect domain isn't listed as a authorized domain for Firebase Authentication, or the API key that you use with the Firebase Authentication Service is invalid.

First make sure that YOUR_REDIRECT_DOMAIN is in thelist of authorized domainsfor your Firebase project. If your redirect domain is already listed there, continue to troubleshoot an invalid API key.

By default, Firebase Authentication JS SDK relies on the API key for your Firebase project that's labeled as the Browser key, and it uses this key to verify that a sign-in redirect URL is valid according to the list of authorized domains.Authentication gets this API key depending on how you access the Authentication SDK:

Check to make sure this API key hasn't been deleted: Go to theAPIs & Services > Credentialspanel in the Google Cloud console where all the API keys for your project are listed.

Authentication: How do I manually construct an OAuth web client?
  1. Open theCredentialspage of the Google Cloud console.
  2. At the top of the page, select Create credentials > OAuth client ID.
  3. If you're prompted to configure your consent screen, follow the on-screen instructions, and then continue with the following steps of this FAQ.
  4. Create the OAuth web client:
    1. For the Application Type, select Web application.
    2. For the Authorized JavaScript Origins, add the following:
      • http://localhost
      • http://localhost:5000
      • https://PROJECT_ID.firebaseapp.com
      • https://PROJECT_ID.web.app
    3. For the Authorized Redirect URIs, add the following:
      • https://PROJECT_ID.firebaseapp.com/__/auth/handler
      • https://PROJECT_ID.web.app/__/auth/handler
    4. Save the OAuth client.
  5. Copy the new OAuth client ID and client secret to your clipboard.
  6. In the Firebase console, open theAuthentication section.
  7. Within the Sign in method tab, open the Google sign-in provider, and then paste the web server client ID and secret you just constructed and copied from the Google Cloud console. Click Save.
Authentication: How is %APP_NAME% determined for the email template for the confirmation email that can be sent to a user when they sign up using an email address and password?

Before December 2022, the %APP_NAME% in the email template was populated with the OAuth brand name that was automatically provisioned whenever an Android app was registered in the Firebase project. Now, since the OAuth brand is provisioned only when Google sign-in is enabled, the following describes how%APP_NAME% is determined:

Note that if the lookup of the default Firebase Hosting site name fails, then the final fallback is to use the Firebase project ID as the %APP_NAME%.


Cloud Functions

Visit the Cloud Functions for Firebase FAQ and Troubleshooting page for troubleshooting help and answers to common questions.


Cloud Messaging

Visit theFCM troubleshooting & FAQ pagefor helpful tips and answers to more FAQs.

Cloud Storage for Firebase

Cloud Storage for Firebase: What are the changes to the default bucket announced in September 2024?

Go to the Cloud Storage documentation to learn more about theChanges for the default Cloud Storage bucket.

Cloud Storage for Firebase: What are the changes to the pricing plan requirements for Cloud Storage announced in September 2024?

Go to the Cloud Storage documentation to learn more about theChanges for pricing plan requirements for Cloud Storage.

Cloud Storage for Firebase: Why do I see an unexpected increase in upload and download operations?

Previously, download and upload requests to theCloud Storage for Firebase API were not being counted properly. We have taken steps to fix this issue, starting from September 15, 2023.

We recommend monitoring yourUsage page for any increases that may count towards your limits.

Cloud Storage for Firebase: How do I predict how much I will be billed for upload and download operations?

Visit the Firebase Pricing page and use theBlaze pricing plan calculator. The calculator lists all the usage types for Cloud Storage for Firebase.

Use the sliders to input the expected usage of your Storage bucket. The calculator will estimate your monthly bill.

Cloud Storage for Firebase: Why am I getting service account permission errors in the console or when using the Cloud Storage for Firebase API (like error code 412)?

Here are some likely reasons for getting these errors:

Cloud Storage for Firebase: Why do I see new or multiple service accounts in my Firebase projects that use Cloud Storage for Firebase?

Firebase uses service accounts to operate and manage services without sharing user credentials. When you create a Firebase project, you might notice that a number of service accounts are already available in your project.

The required service account for Cloud Storage for Firebase is scoped to your project and is named:service-PROJECT_NUMBER@gcp-sa-firebasestorage.iam.gserviceaccount.com.

If you used Cloud Storage for Firebase before September 19, 2022, you may see an additional service account on previously-linked Cloud Storage buckets named:firebase-storage@system.gserviceaccount.com. This old service account is no longer supported as of September 19, 2022.

You can view all service accounts for your project in theService accounts tabof the Firebase console.

Add the required service account if it's missing

If you deleted the required service account or it's not present in your project, you can do one of the following to add the service account.

In the Firebase console, a missing service account might manifest as a failure to add required IAM permissions.

Remove the required service account

We strongly discourage removing the service account because this may block access to your Cloud Storage buckets from your apps. To remove the service account from your project, follow the instructions inDisabling a service account.


Crashlytics

Visit theCrashlytics troubleshooting & FAQ pagefor helpful tips and answers to more FAQs.


See Dynamic Links FAQ.

The getInvitation API clears the saved Dynamic Link to prevent it from being accessed twice. Be sure to call this API with the autoLaunchDeepLink parameter set tofalse in each of the deep link activities to clear it for the case when the activity is triggered outside the main activity.


Hosting

Visit the Firebase Hosting FAQ and Troubleshooting page for answers to common questions.


Performance Monitoring

Visit thePerformance Monitoring troubleshooting & FAQ pagefor helpful tips and answers to more FAQs.


Realtime Database

Realtime Database: What is a "simultaneous database connection"?

A simultaneous connection is equivalent to one mobile device, browser tab, or server app connected to the database. Firebase imposes hard limits on the number of simultaneous connections to your app's database. These limits are in place to protect both Firebase and our users from abuse.

The Spark pricing plan limit is 100 and cannot be raised. The Blaze pricing plan has a limit of 200,000 simultaneous connections per database.

This limit isn't the same as the total number of users of your app, because your users don't all connect at once. If you need more than 200,000 simultaneous connections, review options inScale with multiple databases.

Realtime Database: What are the scaling limitations of theRealtime Database?

Each Realtime Database instance has limits on the number of write operations per second. For small writes, this limit is approximately 1000 write operations per second. If you are approaching this limit,batching operations using multi-path updates can help you achieve higher throughput.

In addition, each database instance hasa cap on the number of simultaneous database connections. Our default limits are large enough for most applications. If you are building an app that requires additional scale, you may need toshard your application across multiple database instances for added scale. You may also considerCloud Firestore as an alternative database.

Realtime Database: What can I do if I'm over my Realtime Database usage limits?

If you've received an email alert or notification in theFirebase console that you've exceeded your Realtime Database usage limits, you can address it based on the usage limit you've exceeded. To see yourRealtime Database usage, go to theRealtime Database Usage dashboard in theFirebase console.

If you're over your download limit, you can upgrade yourFirebase pricing plan or wait until your download limit resets at the start of your next billing cycle. To decrease your downloads, try the following steps:

If you're over your storage limit, upgrade your pricing plan to avoid service disruptions. To reduce the amount of data in your database, try the following steps:

Note that it may take some time to see any data deletions reflected in your storage allotment.

If you're over your simultaneous database connections limit, upgrade your plan to avoid any service disruptions. To manage simultaneous connections to your database, try connecting via users via the REST API if they don't require a realtime connection.

Realtime Database: What happens if I exceed the Spark pricing plan storage or download limits for Realtime Database?

To provide you with a predictable price, the resources available to you are capped when your project is on the Spark pricing plan. This means that when you exceed any plan limit in any month, your app will be turned off to prevent any further resource usage and additional charges.

Realtime Database: What happens if I exceed Spark pricing plan simultaneous connection limits forRealtime Database?

When your app reaches its concurrency limit on the Spark pricing plan, any subsequent connections will be rejected until some of the existing connections are closed. The app will continue to work for users who are connected.

Realtime Database: What are automated backups? Do you offer hourly backups for Realtime Database?

Automated backups are an advanced feature for projects that are on the Blaze pricing plan. This feature backs up your Firebase Realtime Database data once a day and uploads it toGoogle Cloud Storage.

We don't offer hourly backups.

Realtime Database: Why was my Realtime Database reported bandwidth lower than average between September 2016 and March 2017?

For bandwidth calculations, we normally include SSL encryption overhead (based on layer 5 of the OSI model). However, inSeptember 2016, we introduced a bug that caused our bandwidth reporting to ignore encryption overhead. This might have resulted in artificially low reported bandwidth and bills on your account for a few months.

We released a fix for the bug in late March 2017, returning bandwidth reporting and billing to their normal levels.


Remote Config

Visit theRemote Config troubleshooting & FAQ pagefor helpful tips and answers to more FAQs.


Test Lab

Visit theTest Lab troubleshooting pagefor helpful tips and answers to FAQs.


Firebase App Indexing

What happened to Firebase App Indexing?

Firebase App Indexing is no longer the recommended way of indexing content for display as suggested results in Google Search App. This FAQ points to other useful developer products.

Apple platforms

Universal Linksare the recommended way of linking users directly from search results, websites and other apps to specific content within your app.

Android

Android App Linksare the recommended way of linking users directly from search results, websites and other apps to specific content within your app.

You might also be interested in the following options:


Firebase User Segmentation Storage

What is Firebase User Segmentation Storage?

Firebase User Segmentation Storage storesFirebase installation IDs and related attributes and segments as well as audience lists you've created to provide targeting information to other Firebase services that use them, such as Crashlytics, FCM, Remote Config personalization, and more.