پروژه Firebase موجودیت سطح بالایی برای Firebase است. در یک پروژه، می توانید اپلیکیشن های اپل، اندروید یا وب خود را ثبت کنید. پس از ثبت برنامه های خود در Firebase، می توانید SDK های Firebase خاص محصول را به برنامه خود اضافه کنید، مانند Analytics ، Cloud Firestore ، Crashlytics ، یا Remote Config .
شما باید انواع اپل، اندروید و برنامه وب خود را در یک پروژه Firebase ثبت کنید. می توانید از چندین پروژه Firebase برای پشتیبانی از چندین محیط مانند توسعه، مرحله بندی و تولید استفاده کنید.
در اینجا چند منبع برای کسب اطلاعات بیشتر در مورد پروژه های Firebase آورده شده است:
پروژههای Firebase را درک کنید — مروری کوتاه بر چندین مفهوم مهم در مورد پروژههای Firebase، از جمله ارتباط آنها با Google Cloud و سلسله مراتب اساسی یک پروژه و برنامهها و منابع آن ارائه میکند.
بهترین روشهای عمومی برای راهاندازی پروژههای Firebase - بهترین روشهای عمومی و سطح بالا را برای راهاندازی پروژههای Firebase و ثبت برنامههای خود در یک پروژه ارائه میکند تا گردش کار توسعه واضحی داشته باشید که از محیطهای متمایز استفاده میکند.
توجه داشته باشید که برای همه پروژههای Firebase، Firebase به طور خودکار یک برچسب firebase:enabled در صفحه Labels برای پروژه شما در کنسول Google Cloud اضافه میکند. در سؤالات متداول ما درباره این برچسب بیشتر بیاموزید.
سازمان Google Cloud چیست؟
سازمان Google Cloud محفظهای برای پروژههای Google Cloud (از جمله پروژههای Firebase) است. این سلسله مراتب سازماندهی، مدیریت دسترسی و ممیزی بهتر پروژه های Google Cloud و Firebase را امکان پذیر می کند. برای اطلاعات بیشتر به ایجاد و مدیریت سازمان ها مراجعه کنید.
چگونه Firebase را به پروژه Google Cloud موجود اضافه کنم؟
چرا پروژه Google Cloud من دارای برچسب firebase:enabled ؟
در صفحه برچسبها برای پروژه خود در کنسول Google Cloud ، ممکن است برچسب firebase:enabled ببینید (به طور خاص، یک Keyfirebase با Valueenabled ).
Firebase به طور خودکار این برچسب را اضافه کرد زیرا پروژه شما یک پروژه Firebase است، به این معنی که پروژه شما دارای تنظیمات و سرویس های خاص Firebase برای آن فعال است. درباره رابطه بین پروژه های Firebase و Google Cloud بیشتر بیاموزید.
اکیداً توصیه می کنیم که این برچسب را اصلاح یا حذف نکنید. Firebase و Google Cloud از این برچسب برای فهرست کردن پروژههای Firebase شما استفاده میکنند (برای مثال، با استفاده از نقطه پایانی REST API projects.list یا در منوهای کنسول Firebase ).
توجه داشته باشید که افزودن دستی این برچسب به لیست برچسبهای پروژه، تنظیمات و سرویسهای خاص Firebase را برای پروژه Google Cloud شما فعال نمیکند. برای انجام این کار، باید Firebase را از طریق کنسول Firebase (یا برای موارد استفاده پیشرفته، از طریق Firebase Management REST API یا Firebase CLI ) اضافه کنید.
چرا پروژه Firebase من در لیست پروژه های Firebase من نشان داده نمی شود؟
اگر پروژه Firebase خود را در مکانهای زیر نمیبینید، این سؤالات متداول قابل اجرا است:
در لیستی از پروژه هایی که در کنسول Firebase مشاهده می کنید
در پاسخ از اجرای دستور Firebase CLI firebase projects:list
این مراحل عیبیابی را امتحان کنید:
ابتدا سعی کنید با مراجعه مستقیم به URL پروژه به پروژه خود دسترسی پیدا کنید. از فرمت زیر استفاده کنید: https://console.firebase.google.com/project/ PROJECT-ID /overview
اگر نمی توانید به پروژه دسترسی پیدا کنید یا خطاهای مجوز را دریافت کنید، موارد زیر را بررسی کنید:
مطمئن شوید که با استفاده از همان حساب Google که به پروژه دسترسی دارد، وارد Firebase شده اید. میتوانید از طریق آواتار حسابتان در گوشه سمت راست Firebase کنسول وارد و خارج شوید.
مطمئن شوید که پروژه شما دارای برچسب firebase:enabled در صفحه Labels برای پروژه شما در کنسول Google Cloud است. Firebase و Google Cloud از این برچسب برای فهرست کردن پروژههای Firebase شما استفاده میکنند. اگر این برچسب را نمی بینید اما API مدیریت Firebase برای پروژه شما فعال است ، به صورت دستی برچسب را اضافه کنید (به طور خاص، یک Keyfirebase با Valueenabled ).
مطمئن شوید که یکی از نقشهای اصلی IAM (مالک، ویرایشگر، نمایشگر) یا نقشی که مجوزهای مرتبط با Firebase را در خود دارد، به عنوان مثال یک نقش از پیش تعریف شده Firebase به شما اختصاص داده شده است. میتوانید نقش(های) خود را در صفحه IAM کنسول Google Cloud مشاهده کنید.
اگر پروژه شما متعلق به یک سازمان Google Cloud است، ممکن است برای دیدن پروژه فهرست شده در کنسول Firebase به مجوزهای بیشتری نیاز داشته باشید. با فردی که سازمان Google Cloud شما را مدیریت می کند تماس بگیرید تا نقش مناسب را برای مشاهده پروژه به شما بدهد، به عنوان مثال نقش مرورگر.
اگر هیچ یک از مراحل عیبیابی بالا به شما امکان نمیدهد پروژه خود را در لیستی از پروژههای Firebase ببینید، با پشتیبانی Firebase تماس بگیرید.
در هر حساب چند پروژه می توانم داشته باشم؟
طرح قیمت گذاری جرقه - سهمیه پروژه شما محدود به تعداد کمی پروژه است (معمولاً حدود 5-10).
طرح قیمت گذاری Blaze - تا زمانی که حساب Cloud Billing شما وضعیت خوبی داشته باشد، سهمیه پروژه شما به ازای هر حساب Cloud Billing به میزان قابل توجهی افزایش می یابد.
توجه داشته باشید که حذف کامل یک پروژه به 30 روز زمان نیاز دارد و تا حذف کامل سهمیه شما به حساب می آید.
چند برنامه Firebase می توانم در یک پروژه Firebase داشته باشم؟
پروژه Firebase محفظه ای برای برنامه های Firebase در سراسر اپل، اندروید و وب است. Firebase تعداد کل برنامه های Firebase را در پروژه Firebase به 30 محدود می کند.
پس از این تعداد، عملکرد شروع به کاهش میکند (مخصوصاً برای Google Analytics ) و در نهایت، در تعداد بیشتری از برنامهها، برخی از عملکردهای محصول کار نمیکنند. علاوه بر این، اگر از ورود به سیستم Google به عنوان ارائهدهنده احراز هویت استفاده میکنید، یک شناسه مشتری OAuth 2.0 برای هر برنامه در پروژه شما ایجاد میشود. حدود 30 شناسه مشتری وجود دارد که می توان در یک پروژه ایجاد کرد.
باید اطمینان حاصل کنید که همه برنامههای Firebase در یک پروژه Firebase، انواع پلتفرم یک برنامه از دیدگاه کاربر نهایی هستند. به عنوان مثال، اگر یک برنامه white label توسعه میدهید، هر برنامه دارای برچسب مستقل باید پروژه Firebase خود را داشته باشد، اما نسخههای Apple و Android آن برچسب میتوانند در همان پروژه باشند. راهنمای دقیقتر را در بهترین شیوههای کلی ما برای راهاندازی پروژههای Firebase بخوانید.
در موارد نادری که پروژه شما به بیش از 30 برنامه نیاز دارد، می توانید درخواست افزایش محدودیت برنامه کنید. برای ارائه این درخواست، پروژه شما باید در برنامه قیمت گذاری Blaze باشد. برای ارائه درخواست و ارزیابی آن به کنسول Google Cloud مراجعه کنید. درباره مدیریت سهمیه در اسناد Google Cloud بیشتر بیاموزید.
اگر پروژه خود را به عنوان یک محیط "تولید" برچسب گذاری کنم چه اتفاقی می افتد؟
در کنسول Firebase ، میتوانید پروژههای Firebase خود را با نوع محیط آنها به عنوان محیطهای تولیدی یا نامشخص (غیر تولیدی) برچسبگذاری کنید.
برچسب زدن پروژه شما به عنوان یک نوع محیط تاثیری بر نحوه کار پروژه Firebase یا ویژگی های آن ندارد. با این حال، برچسبگذاری میتواند به شما و تیمتان کمک کند تا پروژههای مختلف Firebase خود را برای چرخه حیات برنامه مدیریت کنید.
اگر پروژه خود را بهعنوان یک محیط تولید برچسبگذاری کنید، یک تگ Prod با رنگ روشن به پروژه در کنسول Firebase اضافه میکنیم و به شما یادآوری میکنیم که هر گونه تغییری میتواند بر برنامههای تولید مرتبط شما تأثیر بگذارد. در آینده، ممکن است ویژگیها و حفاظتهای بیشتری را برای پروژههای Firebase که به عنوان محیطهای تولید برچسبگذاری شدهاند، اضافه کنیم.
برای تغییر نوع محیط پروژه Firebase خود، به settingsProject settings > General بروید، سپس در Your project card در قسمت Environment ، روی edit کلیک کنید تا نوع محیط را تغییر دهید.
از کجا می توانم شناسه برنامه را برای برنامه Firebase خود پیدا کنم؟
در کنسول Firebase ، به settings خود، تنظیمات پروژه بروید. به سمت پایین به کارت برنامه های شما بروید، سپس روی برنامه Firebase مورد نظر کلیک کنید تا اطلاعات برنامه، از جمله شناسه برنامه آن را مشاهده کنید.
در اینجا چند نمونه از مقادیر App ID آورده شده است:
برنامه های Firebase iOS: 1:1234567890:ios:321abc456def7890
برنامه های اندروید Firebase: 1:1234567890:android:321abc456def7890
برنامه های وب Firebase: 1:1234567890:web:321abc456def7890
پیش نیازهای پیوند Google Play / AdMob / Google Ads / BigQuery به پروژه یا برنامه Firebase من چیست؟
یکی از نقش های Firebase زیر: مالک یا مدیر Firebase و
یکی از سطوح دسترسی Google Play زیر: مالک یا سرپرست حساب
برای پیوند دادن برنامه AdMob خود، باید هم مالک پروژه Firebase و هم یک سرپرست AdMob باشید.
برای پیوند دادن حساب AdWords خود، باید هم مالک پروژه Firebase و هم مدیر AdWords باشید.
برای پیوند دادن پروژه BigQuery خود، باید مالک پروژه Firebase باشید.
چه اعلان های منبع باز را باید در برنامه خود قرار دهم؟
در پلتفرمهای اپل، پاد Firebase حاوی یک فایل NOTICES است که شامل ورودیهای مربوطه است. Firebase Android SDK حاوی یک Activity کمکی برای نمایش اطلاعات مجوز است.
مجوزها و دسترسی به پروژه های Firebase
چگونه می توانم نقشی مانند نقش مالک را به یک عضو پروژه اختصاص دهم؟
برای مدیریت نقش(های) اختصاص داده شده به هر یک از اعضای پروژه، باید مالک پروژه Firebase باشید (یا نقشی با مجوز resourcemanager.projects.setIamPolicy به شما اختصاص داده شود).
در اینجا مکان هایی وجود دارد که می توانید نقش ها را تعیین و مدیریت کنید:
کنسول Google Cloud مجموعه گسترده ای از ابزارها را برای اختصاص نقش به اعضای پروژه در صفحه IAM ارائه می دهد. در کنسول Cloud ، همچنین میتوانید نقشهای سفارشی ایجاد و مدیریت کنید، و همچنین به حسابهای خدماتی اجازه دسترسی به پروژه خود را بدهید.
توجه داشته باشید که در کنسول Google Cloud ، به اعضای پروژه، اصلی گفته می شود.
اگر مالک پروژه شما دیگر نمی تواند وظایف مالک را انجام دهد (به عنوان مثال، شخصی که شرکت شما را ترک کرده است) و پروژه شما از طریق یک سازمان Google Cloud مدیریت نمی شود (به پاراگراف بعدی مراجعه کنید)، می توانید با پشتیبانی Firebase تماس بگیرید و بررسی کنید. با آنها در مورد نحوه درخواست دسترسی به پروژه Firebase.
توجه داشته باشید که اگر پروژه Firebase بخشی از یک سازمان Google Cloud باشد، ممکن است مالک نداشته باشد. اگر نمیتوانید مالکی برای پروژه Firebase خود پیدا کنید، با فردی که سازمان Google Cloud شما را مدیریت میکند تماس بگیرید تا مالکی را برای پروژه تعیین کند.
چگونه مالک پروژه Firebase را پیدا کنم؟
می توانید اعضای پروژه و نقش آنها را در مکان های زیر مشاهده کنید:
اگر در کنسول Firebase به پروژه دسترسی دارید، می توانید لیست اعضای پروژه از جمله مالکان را در صفحه کاربران و مجوزهای کنسول Firebase مشاهده کنید.
اگر در کنسول Firebase به پروژه دسترسی ندارید ، بررسی کنید که آیا به پروژه در کنسول Google Cloud دسترسی دارید یا خیر. میتوانید فهرست اعضای پروژه از جمله مالکان را در صفحه IAM کنسول Google Cloud مشاهده کنید.
اگر مالک پروژه شما دیگر نمی تواند وظایف مالک را انجام دهد (به عنوان مثال، شخصی که شرکت شما را ترک کرده است) و پروژه شما از طریق یک سازمان Google Cloud مدیریت نمی شود (به پاراگراف بعدی مراجعه کنید)، می توانید با پشتیبانی Firebase تماس بگیرید . یک مالک موقت اختصاص داده شده است.
توجه داشته باشید که اگر پروژه Firebase بخشی از یک سازمان Google Cloud باشد، ممکن است مالک نداشته باشد. درعوض، شخصی که سازمان Google Cloud شما را مدیریت میکند، میتواند کارهای زیادی را انجام دهد که مالک میتواند انجام دهد. با این حال، برای انجام چندین کار خاص مالک (مانند تخصیص نقشها یا مدیریت ویژگیهای Google Analytics )، ممکن است لازم باشد سرپرست برای انجام آن وظایف ، نقش مالک واقعی را به خود اختصاص دهد. اگر نمیتوانید مالکی برای پروژه Firebase خود پیدا کنید، با فردی که سازمان Google Cloud شما را مدیریت میکند تماس بگیرید تا مالکی را برای پروژه تعیین کند.
چرا یا چه زمانی باید نقش مالک را به یکی از اعضای پروژه اختصاص دهم؟
برای اطمینان از مدیریت صحیح پروژه Firebase، باید مالک داشته باشد. مالک پروژه شخصی است که میتواند چندین عمل مهم اداری (مانند اختصاص نقشها و مدیریت ویژگیهای Google Analytics ) را انجام دهد و Firebase Support تنها میتواند درخواستهای مدیریتی مالکان پروژه نشانداده شده را برآورده کند.
پس از تنظیم مالک(ها) برای پروژه Firebase، مهم است که آن تکالیف را به روز نگه دارید.
توجه داشته باشید که اگر پروژه Firebase بخشی از یک سازمان Google Cloud باشد، شخصی که سازمان Google Cloud شما را مدیریت میکند میتواند بسیاری از وظایفی را که مالک میتواند انجام دهد، انجام دهد. با این حال، برای چندین کار خاص مالک (مانند تخصیص نقشها یا مدیریت ویژگیهای Google Analytics )، ممکن است لازم باشد سرپرست برای انجام آن وظایف ، نقش مالک واقعی را به خود اختصاص دهد.
فکر نمی کنم پروژه Firebase داشته باشم، اما یک ایمیل در مورد آن دریافت کردم. چگونه به این پروژه دسترسی داشته باشم؟
ایمیلی که دریافت کردید باید حاوی پیوندی برای باز کردن پروژه Firebase شما باشد. با کلیک روی پیوند در ایمیل، پروژه در کنسول Firebase باز می شود.
اگر نمیتوانید پروژه را در پیوند باز کنید، مطمئن شوید که با استفاده از همان حساب Google که ایمیل پروژه را دریافت کرده، وارد Firebase شدهاید. میتوانید از طریق آواتار حسابتان در گوشه سمت راست Firebase کنسول وارد و خارج شوید.
توجه داشته باشید که اگر سرپرست یک سازمان Google Cloud هستید، ممکن است از تغییرات پروژه های Firebase در داخل سازمان خود مطلع شوید. با این حال، ممکن است مجوز کافی برای باز کردن پروژه Firebase نداشته باشید. در این موارد، ساده ترین راه حل این است که برای باز کردن پروژه و انجام اقدامات لازم ، نقش مالک واقعی را به خود اختصاص دهید. درباره علت و زمان اختصاص دادن نقش مالک بیشتر بیاموزید.
پلتفرم ها و چارچوب ها
برای دریافت نکات و پاسخهای مفید برای سؤالات متداول بیشتر، از صفحات عیبیابی و سؤالات متداول مخصوص پلتفرم دیدن کنید.
مرورگرهای پشتیبانی شده برای دسترسی به کنسول Firebase کدامند؟
کنسول Firebase از نسخه های اخیر مرورگرهای محبوب دسکتاپ مانند کروم، فایرفاکس، سافاری و اج قابل دسترسی است. مرورگرهای موبایل در حال حاضر به طور کامل پشتیبانی نمی شوند.
من می توانم کنسول Firebase را بارگیری کنم، اما چرا نمی توانم پروژه Firebase خود را پیدا کنم یا به آن دسترسی پیدا کنم؟
اگر با یکی از مشکلات زیر مواجه هستید، این سؤالات متداول قابل اجرا است:
کنسول Firebase صفحه خطایی را برمی گرداند که می گوید پروژه شما ممکن است وجود نداشته باشد یا به پروژه دسترسی نداشته باشید.
کنسول Firebase حتی زمانی که ID پروژه یا نام پروژه آن را در قسمت جستجوی کنسول وارد میکنید، پروژه شما را نمایش نمیدهد.
این مراحل عیبیابی را امتحان کنید:
ابتدا سعی کنید با مراجعه مستقیم به URL پروژه به پروژه خود دسترسی پیدا کنید. از فرمت زیر استفاده کنید: https://console.firebase.google.com/project/ PROJECT-ID /overview
اگر هنوز نمی توانید به پروژه دسترسی داشته باشید یا خطاهای مجوز را دریافت کنید، موارد زیر را بررسی کنید:
مطمئن شوید که با استفاده از همان حساب Google که به پروژه دسترسی دارد، وارد Firebase شده اید. میتوانید از طریق آواتار حسابتان در گوشه سمت راست Firebase کنسول وارد و خارج شوید.
مطمئن شوید که یکی از نقشهای اصلی IAM (مالک، ویرایشگر، نمایشگر) یا نقشی که مجوزهای مرتبط با Firebase را در خود دارد، به عنوان مثال یک نقش از پیش تعریف شده Firebase به شما اختصاص داده شده است. میتوانید نقش(های) خود را در صفحه IAM کنسول Google Cloud مشاهده کنید.
اگر پروژه شما متعلق به یک سازمان Google Cloud است، ممکن است برای دیدن پروژه فهرست شده در کنسول Firebase به مجوزهای بیشتری نیاز داشته باشید. با فردی که سازمان Google Cloud شما را مدیریت می کند تماس بگیرید تا نقش مناسب را برای مشاهده پروژه به شما بدهد، به عنوان مثال نقش مرورگر.
اگر هیچ یک از مراحل عیبیابی بالا به شما امکان نمیدهد پروژه خود را پیدا کنید یا به آن دسترسی پیدا کنید، با پشتیبانی Firebase تماس بگیرید.
چرا کنسول Firebase برای من بار نمی شود؟
اگر با هر یک از مشکلات زیر مواجه هستید، این سؤالات متداول قابل اجرا است:
بارگذاری صفحه در کنسول Firebase هرگز تمام نمی شود.
داده های داخل یک صفحه همانطور که انتظار می رود بارگیری نمی شود.
هنگام بارگیری کنسول Firebase ، پیام های خطای مرورگر را دریافت می کنید.
مالک پروژه میتواند اعضای دیگری را به پروژه اضافه کند، ادغامها را راهاندازی کند (پیوند پروژه به سرویسهایی مانند BigQuery یا Slack)، و دسترسی ویرایش کاملی برای پروژه داشته باشد.
یک ویرایشگر پروژه دسترسی کامل به ویرایش پروژه را دارد.
یک نمایشگر پروژه فقط دسترسی خواندن برای پروژه دارد. توجه داشته باشید که کنسول Firebase در حال حاضر کنترلهای ویرایش UI را از بینندگان پروژه پنهان/غیرفعال نمیکند، اما این عملیات برای اعضای پروژه که نقش Viewer را به آنها اختصاص دادهاند، با شکست مواجه میشوند.
Firebase همچنین پشتیبانی می کند:
نقشهای از پیش تعریفشده Firebase - نقشهای خاص Firebase انتخابشده که کنترل دسترسی دقیقتری را نسبت به نقشهای اصلی Owner، Editor و Viewer فعال میکنند.
نقشهای سفارشی - نقشهای IAM کاملاً سفارشیسازیشده که شما ایجاد میکنید تا مجموعهای از مجوزها را مطابق با الزامات خاص سازمان شما تنظیم کنید.
قیمت گذاری
کدام محصولات پرداخت می شوند؟ کدام بدون هزینه هستند؟
محصولات زیرساخت پولی Firebase عبارتند از: Realtime Database ، Cloud Storage for Firebase ، Cloud Functions ، Hosting ، Test Lab و احراز هویت تلفن. ما یک ردیف بدون هزینه برای همه این ویژگی ها ارائه می دهیم.
Firebase همچنین دارای بسیاری از محصولات بدون هزینه است: Analytics ، Cloud Messaging ، سازنده اعلانها، Remote Config ، App Indexing ، Dynamic Links ، و Crash Reporting . استفاده از این محصولات فقط مشمول سیاستهای کنترل ترافیک محصول (به عنوان مثال سهمیهبندی، دسترسی منصفانه و سایر حفاظتهای خدمات) در همه طرحها، از جمله طرح بدون هزینه Spark ما است. علاوه بر این، تمام ویژگیهای Authentication فراتر از احراز هویت تلفن، بدون هزینه هستند.
آیا Firebase اعتبار آزمایشی بدون هزینه برای محصولات پولی ارائه می دهد؟
خدمات پولی Firebase را میتوان تحت آزمایش رایگان Google Cloud استفاده کرد. کاربران جدید Google Cloud و Firebase میتوانند از یک دوره آزمایشی 90 روزه استفاده کنند که شامل 300 دلار اعتبار رایگان Cloud Billing برای کاوش و ارزیابی محصولات و خدمات Google Cloud و Firebase است.
در طول دوره آزمایشی رایگان Google Cloud ، یک حساب رایگان آزمایشی Cloud Billing به شما ارائه می شود. هر پروژه Firebase که از آن حساب صورتحساب استفاده میکند، در طول دوره آزمایشی رایگان، در طرح قیمتگذاری Blaze قرار میگیرد.
نگران نباشید، راهاندازی این حساب Cloud Billing آزمایشی رایگان به ما امکان نمیدهد از شما هزینه دریافت کنیم. هزینهای از شما کسر نمیشود مگر اینکه با ارتقای حساب آزمایشی رایگان Cloud Billing خود به حساب پولی، صورتحساب را صریحاً فعال کنید. میتوانید در طول دوره آزمایشی، در هر زمانی به یک حساب پولی ارتقا دهید. پس از ارتقاء، همچنان میتوانید از اعتبارات باقیمانده (در بازه زمانی 90 روزه) استفاده کنید.
پس از انقضای دوره آزمایشی رایگان، باید پروژه خود را به طرح قیمت گذاری Spark تنزل دهید یا طرح قیمت گذاری Blaze را در کنسول Firebaseتنظیم کنید تا به استفاده از پروژه Firebase خود ادامه دهید.
چگونه بفهمم کدام طرح قیمت گذاری برای من مناسب است؟
طرح قیمت گذاری اسپارک
طرح اسپارک ما مکانی عالی برای توسعه اپلیکیشن شما بدون هزینه است. شما تمام ویژگیهای Firebase بدون هزینه ( Analytics ، آهنگساز Notifications، Crashlytics ، و غیره) و مقادیر سخاوتمندانه ویژگیهای زیرساخت پولی ما را دریافت میکنید. با این حال، اگر در یک ماه تقویمی از منابع طرح Spark خود فراتر بروید، برنامه شما برای باقیمانده آن ماه خاموش خواهد شد. علاوه بر این، ویژگیهای Google Cloud هنگام استفاده از طرح Spark در دسترس نیستند.
طرح قیمت گذاری بلیز
طرح Blaze ما برای برنامه های تولیدی طراحی شده است. طرح Blaze همچنین به شما امکان می دهد برنامه خود را با ویژگی های پولی Google Cloud گسترش دهید. شما فقط برای منابعی که مصرف می کنید هزینه می پردازید و به شما امکان می دهد تا با تقاضا مقیاس بندی کنید. ما در تلاش هستیم تا قیمت طرح Blaze خود را با ارائه دهندگان ابر پیشرو در صنعت رقابتی کنیم.
پیامک رایگان در طرح اسپارک چه شد؟
از سپتامبر 2024، برای بهبود امنیت و کیفیت خدمات احراز هویت تلفن، پروژههای Firebase باید به یک حساب صورتحساب Cloud پیوند داده شوند تا سرویس پیامک فعال شود و از آن استفاده شود.
چگونه می توانم استفاده و صورتحساب خود را کنترل کنم؟
می توانید استفاده خود از منابع پروژه را در کنسول Firebase در هر یک از داشبوردهای زیر دنبال کنید:
در ژانویه 2020، طرح قیمت گذاری Flame (25 دلار در ماه سهمیه اضافی) به عنوان گزینه ای برای ثبت نام های جدید حذف شد. به کاربران طرح موجود مهلتی اعطا شد تا پروژه های خود را به خارج از طرح Flame منتقل کنند. در فوریه 2022، پروژههای باقیمانده در طرح قیمتگذاری Flame به طرح قیمتگذاری اسپارک تنزل یافتند. بر این اساس،
پروژه های موجود طرح Spark و Blaze و هر پروژه جدید دیگر نمی توانند به طرح Flame تغییر یا ثبت نام کنند.
اگر یک پروژه طرح Flame موجود را به یک طرح قیمت گذاری متفاوت منتقل کنید، پروژه نمی تواند به طرح Flame برگردد.
پروژه هایی که به طرح Spark تنزل داده شده اند را می توان به طرح Blaze ارتقا داد تا خدمات پولی اضافی از سر گرفته شود.
ارجاع به طرح شعله از اسناد حذف شده است.
آیا سؤال بیشتری در مورد بازنشستگی طرح شعله دارید؟ برخی از سؤالات متداول اضافی را در زیر بخوانید.
آیا می خواهید در مورد سایر طرح های قیمت گذاری ارائه شده توسط Firebase اطلاعات کسب کنید؟ از صفحه قیمت گذاری Firebase ما دیدن کنید! اگر میخواهید شروع به انتقال پروژههای موجود به طرح قیمتگذاری دیگری کنید، میتوانید این کار را در کنسول Firebase برای پروژه خود انجام دهید.
سوالات متداول اضافی درباره بازنشستگی طرح شعله
من یک پروژه یا یک فرآیند یا یک مدل کسب و کار دارم که متکی بر هزینه Firebase ثابت است. چه کار کنم؟
آیا می توانم برای ایجاد پروژه های جدید طرح Flame به من دسترسی ویژه داده شود؟
خیر، Firebase دسترسی ویژه ای برای پروژه ها برای تغییر یا ثبت نام در طرح Flame ارائه نمی دهد.
من پروژه طرح Flame خود را به یک طرح قیمت گذاری متفاوت تغییر دادم. چطوری دوباره عوضش کنم؟
تغییر به طرح Flame دیگر امکان پذیر نیست. برای دسترسی به خدمات ارائه شده توسط طرح Flame، مطمئن شوید که از طرح قیمت گذاری Blaze استفاده می کنید و هشدارهای بودجه را برای پروژه خود تنظیم کنید.
پروژه من به عنوان بخشی از بازنشستگی طرح شعله به طور خودکار به یک طرح قیمت گذاری متفاوت تغییر یافت. چه کار کنم؟
اگر پروژه شما به سهمیه اضافی فراتر از آنچه در طرح Spark ارائه شده است نیاز دارد، باید پروژه خود را به طرح قیمت گذاری Blaze ارتقا دهید.
چرا طرح شعله بازنشسته می شود؟
در طول سالها، ما شاهد کاهش استفاده از طرح Flame بودهایم و اکثر پروژههایی که از این طرح استفاده میکنند ارزش کامل آن را مصرف نمیکنند. حفظ این طرح قیمتگذاری عموماً مقرون به صرفه نیست، و ما احساس میکنیم که اگر منابع به سایر طرحهای Firebase بروند، میتوانیم به همه خدمات بهتری ارائه دهیم.
استفاده بدون هزینه در طرح Blaze چه تفاوتی با استفاده بدون هزینه در طرح Spark دارد؟
استفاده بدون هزینه در طرح Blaze روزانه محاسبه می شود. محدودیتهای استفاده نیز با طرح Spark برای Cloud Functions ، احراز هویت تلفن و Test Lab متفاوت است.
برای Cloud Functions ، استفاده بدون هزینه در طرح Blaze در سطح حساب Cloud Billing محاسبه میشود، نه در سطح پروژه و دارای محدودیتهای زیر است:
2 میلیون فراخوان در ماه
400 هزار گیگابایت ثانیه در ماه
200K CPU-ثانیه در ماه
5 گیگابایت خروجی شبکه در ماه
برای احراز هویت تلفن، استفاده بدون هزینه در طرح Blaze به صورت ماهانه محاسبه می شود.
برای Test Lab ، استفاده بدون هزینه در طرح Blaze دارای محدودیتهای زیر است:
30 دقیقه دستگاه فیزیکی در روز
60 دقیقه دستگاه مجازی در روز
آیا وقتی از طرح Spark به Blaze تغییر می کنم، سهمیه استفاده بدون هزینه بازنشانی می شود؟
استفاده بدون هزینه از طرح Spark در طرح Blaze گنجانده شده است. هنگام انتقال به طرح Blaze، استفاده بدون هزینه بازنشانی نمیشود.
"اتصال همزمان پایگاه داده" چیست؟
یک اتصال همزمان معادل یک دستگاه تلفن همراه، برگه مرورگر یا برنامه سرور متصل به پایگاه داده است. Firebase محدودیت های سختی را برای تعداد اتصالات همزمان به پایگاه داده برنامه شما اعمال می کند. این محدودیتها برای محافظت از Firebase و کاربران ما در برابر سوء استفاده وجود دارد.
سقف طرح اسپارک 100 است و قابل افزایش نیست. طرح های Flame و Blaze دارای محدودیت 200000 اتصال همزمان در هر پایگاه داده هستند.
این محدودیت با تعداد کل کاربران برنامه شما یکسان نیست، زیرا همه کاربران شما به یکباره متصل نمی شوند. اگر به بیش از 200000 اتصال همزمان نیاز دارید، لطفاً مقیاس با چندین پایگاه داده را بخوانید.
اگر از محدودیتهای ذخیرهسازی یا بارگیری طرح Spark برای Realtime Database تجاوز کنم، چه اتفاقی میافتد؟
برای ارائه قیمت قابل پیش بینی به شما، منابع در دسترس شما در طرح های Spark محدود شده است. این بدان معناست که وقتی در هر ماه از هر محدودیت طرحی فراتر میروید، برنامه شما خاموش میشود تا از مصرف بیشتر منابع و هزینههای اضافی جلوگیری شود.
اگر از محدودیت های اتصال همزمان طرح Spark برای Realtime Database تجاوز کنم چه اتفاقی می افتد؟
وقتی برنامه شما به محدودیت همزمانی خود در طرح Spark رسید، هر گونه اتصال بعدی تا زمانی که برخی از اتصالات موجود بسته نشود، رد می شود. این برنامه برای کاربرانی که متصل هستند به کار خود ادامه خواهد داد.
ادغام Firebase با Google Cloud چگونه کار می کند؟
Firebase عمیقاً با Google Cloud یکپارچه شده است. پروژهها بین Firebase و Google Cloud به اشتراک گذاشته میشوند، بنابراین پروژهها میتوانند خدمات Firebase و سرویسهای Google Cloud را فعال کنند. می توانید از کنسول Firebase یا کنسول Google Cloud به همان پروژه دسترسی داشته باشید. به طور مشخص:
برخی از محصولات Firebase مستقیماً توسط Google Cloud پشتیبانی می شوند، مانند Cloud Storage for Firebase . فهرست محصولاتی که توسط Google Cloud پشتیبانی میشوند به مرور زمان به رشد خود ادامه خواهند داد.
بسیاری از تنظیمات شما، از جمله همکاران و اطلاعات صورتحساب، توسط Firebase و Google Cloud به اشتراک گذاشته میشوند. استفاده شما از Firebase و Google Cloud در یک صورتحساب نشان داده می شود.
بهعلاوه، وقتی به طرح Blaze ارتقا میدهید، میتوانید از هر یک از زیرساختها بهعنوان سرویس و APIهای کلاس جهانی Google Cloud مستقیماً در پروژه Firebase خود با قیمت استاندارد Google Cloud استفاده کنید. همچنین می توانید داده ها را از Google Cloud مستقیماً به BigQuery برای تجزیه و تحلیل صادر کنید. برای کسب اطلاعات بیشتر، لینک BigQuery با Firebase را ببینید.
استفاده از Google Cloud با Firebase مزایای زیادی برای افزایش امنیت، بهبود تاخیر و صرفه جویی در زمان دارد (در مقابل سایر سرویسهای ابری که در محل مشترک قرار نمیگیرند). برای جزئیات بیشتر، سایت Google Cloud را بررسی کنید.
اگر حسابهای صورتحساب آن پروژه را در کنسول Google Cloud اضافه یا حذف کنم، برای پروژه Firebase من چه اتفاقی میافتد؟
اگر یک حساب Cloud Billing به پروژه ای در کنسول Google Cloud اضافه شود، اگر آن پروژه در حال حاضر در طرح Spark باشد، همان پروژه به طور خودکار به طرح Firebase Blaze ارتقا می یابد.
در مقابل، اگر یک حساب فعال Cloud Billing از پروژهای در کنسول Google Cloud حذف شود، آن پروژه به طرح Firebase Spark تنزل داده میشود.
آیا میتوانم هر زمان که بخواهم ارتقا، کاهش یا لغو کنم؟
بله، میتوانید هر زمان که بخواهید ارتقا، کاهش یا لغو کنید. توجه داشته باشید که ما بازپرداخت نسبتاً برای کاهش یا لغو رتبه ارائه نمی کنیم. این بدان معنی است که اگر قبل از پایان دوره صورتحساب خود را کاهش یا لغو کنید، همچنان برای باقیمانده ماه پرداخت می کنید.
چه نوع حمایتی دریافت خواهم کرد؟
همه برنامههای Firebase، از جمله برنامههایی که از طرحهای بدون هزینه استفاده میکنند، با پشتیبانی ایمیل کارکنان Firebase در ساعات کاری اقیانوس آرام ایالات متحده ارائه میشوند. همه حسابها پشتیبانی نامحدودی از مسائل مربوط به صورتحساب، مسائل مربوط به حساب، سوالات فنی (عیبیابی) و گزارشهای رویداد دارند.
آیا می توانم استفاده از طرح Blaze را محدود کنم؟
نه، در حال حاضر نمی توانید میزان استفاده از طرح Blaze خود را محدود کنید. ما در حال ارزیابی گزینههایی برای حمایت از سقف در استفاده از طرح Blaze هستیم.
کاربران Blaze می توانند بودجه ای برای پروژه یا حساب خود تعریف کنند و با نزدیک شدن هزینه هایشان به این محدودیت ها هشدار دریافت کنند. نحوه تنظیم هشدارهای بودجه را بیاموزید.
پشتیبان گیری خودکار چیست؟ آیا پشتیبان گیری ساعتی ارائه می دهید؟
پشتیبانگیری خودکار یک ویژگی پیشرفته برای مشتریان در طرح قیمتگذاری Blaze ما است که یک بار در روز از دادههای Firebase Realtime Database شما نسخه پشتیبان تهیه میکند و آن را در Google Cloud Storage آپلود میکند.
ما پشتیبان گیری ساعتی ارائه نمی دهیم.
آیا تخفیف های متن باز، غیرانتفاعی یا آموزشی ارائه می دهید؟
طرح Spark ما می تواند توسط هر نوع فرد یا سازمانی، از جمله سازمان های غیرانتفاعی، مدارس، و پروژه های منبع باز استفاده شود. از آنجایی که این طرحها از قبل شامل سهمیههای سخاوتمندانه هستند، ما هیچ تخفیف یا طرح خاصی برای پروژههای منبع باز، غیرانتفاعی یا آموزشی ارائه نمیدهیم.
آیا قراردادهای شرکت ، قیمت گذاری ، پشتیبانی یا میزبانی زیرساخت اختصاصی را ارائه می دهید؟
برنامه Blaze ما برای شرکت های مختلف مناسب است و SLA ما از استاندارد صنعت برای زیرساخت های ابری برخوردار یا فراتر می رود. با این حال ، ما در حال حاضر قراردادهای شرکت ، قیمت گذاری یا پشتیبانی را ارائه نمی دهیم ، و همچنین میزبانی زیرساخت های اختصاصی (یعنی نصب های داخلی) را برای خدماتی مانند Realtime Database ارائه نمی دهیم. ما در حال اضافه کردن برخی از این ویژگی ها هستیم.
آیا قیمت گذاری موقت را ارائه می دهید؟ من فقط برای یک یا دو ویژگی می خواهم پرداخت کنید.
ما قیمت گذاری موقت را در برنامه Blaze ارائه می دهیم ، جایی که شما فقط برای ویژگی هایی که استفاده می کنید پرداخت می کنید.
چگونه برنامه های Firebase پرداخت شده با Ads کار می کنند؟ آیا اعتبار تبلیغاتی بدون هزینه با برنامه های پرداخت شده وجود دارد؟
برنامه های قیمت گذاری Firebase جدا از Ads است ، بنابراین هیچ اعتبار تبلیغاتی بدون هزینه وجود ندارد. به عنوان یک توسعه دهنده Firebase ، شما قادر به "پیوند" حساب Ads خود به Firebase برای پشتیبانی از ردیابی تبدیل هستید.
کلیه کمپین های تبلیغاتی مستقیماً در Ads مدیریت می شوند و صورتحساب Ads از کنسول Ads مدیریت می شود.
قیمت گذاری Cloud Functions
چرا برای استفاده Cloud Functions for Firebase به یک حساب صورتحساب نیاز دارم؟
Cloud Functions for Firebase به برخی از خدمات Google پرداخت شده متکی است. استقرار عملکرد جدید با Firebase CLI 11.2.0 و بالاتر به Cloud Build و Artifact Registry متکی است. استقرار در نسخه های قدیمی تر از Cloud Build به همان روش استفاده می کند ، اما به جای Artifact Registry به Container Registry و Cloud Storage برای ذخیره سازی متکی است. استفاده از این خدمات علاوه بر قیمت گذاری موجود صورتحساب می شود.
فضای ذخیره سازی برای Firebase CLI 11.2.0 و نسخه های جدیدتر
Artifact Registry ظروف را در اختیار شما قرار می دهد. Artifact Registry 500 مگابایت اول را بدون هیچ هزینه ای فراهم می کند ، بنابراین اولین کارآزمایی عملکرد شما ممکن است هیچ هزینه ای متحمل نشود. بالاتر از آن آستانه ، هر گیگابایت اضافی ذخیره سازی با قیمت 0.10 دلار در هر ماه صورتحساب می شود.
فضای ذخیره سازی برای Firebase CLI 11.1.x و نسخه های قبلی
برای توابع مستقر در نسخه های قدیمی تر ، Container Registry ، ظروف را در اختیار شما قرار می دهد. برای هر ظرف مورد نیاز برای استقرار یک تابع صورتحساب می شود. ممکن است برای هر ظرف ذخیره شده ، هزینه های کوچکی را مشاهده کنید - برای مثال ، 1 گیگابایت ذخیره سازی با 0.026 دلار در ماه صورتحساب می شود.
برای درک بیشتر در مورد چگونگی تغییر صورتحساب شما ، لطفاً موارد زیر را مرور کنید
آیا Cloud Functions for Firebase هنوز هیچ هزینه ای ندارد؟
بله. در برنامه Blaze ، Cloud Functions یک ردیف بدون هزینه برای دعوت ها ، زمان محاسبه و ترافیک اینترنت فراهم می کند. اولین 2،000،000 دعوت نامه ، 400000 GB-SEC ، 200،000 CPU-SEC و 5 گیگابایت ترافیک اینترنت در اینترنت بدون هیچ هزینه ای در هر ماه ارائه می شود. شما فقط برای استفاده بالاتر از آن آستانه ها شارژ می شوید.
پس از 500 مگابایت اول ذخیره بدون هزینه ، هر عملیات استقرار هزینه های در مقیاس کوچک را برای فضای ذخیره سازی مورد استفاده برای ظرف عملکرد متحمل می شود. اگر روند توسعه شما به استفاده از توابع برای آزمایش بستگی دارد ، می توانید با استفاده از Firebase Local Emulator Suite در هنگام توسعه ، هزینه ها را به حداقل برسانید.
آیا Firebase قصد دارد سهمیه ها و محدودیت هایی را برای Cloud Functions for Firebase افزایش دهد؟
نه. هیچ برنامه ای برای تغییر سهمیه به جز حذف حداکثر محدودیت زمانی ساخت وجود ندارد. به جای دریافت خطاها یا هشدارها هنگام رسیدن به سهمیه ساخت روزانه 120 دقیقه ، شما طبق برنامه قیمت گذاری Blaze صورتحساب می شوید. به سهمیه ها و محدودیت ها مراجعه کنید.
آیا می توانم اعتبار Google Cloud 300 دلار دریافت کنم؟
بله ، می توانید یک حساب Cloud Billing در کنسول Google Cloud ایجاد کنید تا اعتبار 300 دلاری را بدست آورید ، سپس آن حساب Cloud Billing را به یک پروژه Firebase پیوند دهید.
اطلاعات بیشتر در مورد اعتبار Google Cloudدر اینجا .
توجه داشته باشید که اگر این کار را انجام دهید ، باید برنامه قیمت گذاری Blaze را در کنسول Firebaseتنظیم کنید تا پروژه شما پس از اتمام اعتبار 300 دلاری ، به کار خود ادامه دهد.
من می خواهم برای کسب اطلاعات در مورد Firebase ، یک CodeLab را دنبال کنم. آیا می توانید یک حساب صورتحساب موقت به من بدهید؟
نه متاسفم شما می توانید بدون داشتن حساب Cloud Billingاز Emulator Firebase برای توسعه استفاده کنید. از طرف دیگر ، سعی کنید یک آزمایش رایگان Google Cloud را درخواست کنید. اگر به دلیل این تغییر هنوز در پرداخت صورتحساب خود مشکل دارید ، با پشتیبانی Firebase تماس بگیرید.
من نگرانم که قصد دارم یک صورتحساب بزرگ را جمع کنم.
برای استفاده از برنامه های افزودنی ، باید به برنامه قیمت گذاری Blaze ارتقا دهید. مبلغ کمی (به طور معمول حدود 0.01 دلار در ماه برای منابع آتش نشانی مورد نیاز هر برنامه نصب شده شما (حتی اگر از آنها استفاده نشود) ، علاوه بر هرگونه هزینه مرتبط با استفاده شما از خدمات Firebase ، به شما پرداخت می شود.
Cloud Storage for Firebase
چگونه می توانم پیش بینی کنم که چقدر برای انجام عملیات بارگذاری و بارگیری صورتحساب می شوم؟
به صفحه قیمت گذاری Firebase مراجعه کرده و از ماشین حساب Blaze Plan استفاده کنید. این ماشین حساب تمام انواع استفاده برای Cloud Storage for Firebase را لیست می کند.
برای وارد کردن استفاده مورد انتظار سطل ذخیره سازی خود از کشویی استفاده کنید. ماشین حساب قبض ماهانه شما را تخمین می زند.
چه اتفاقی می افتد اگر من از برنامه Spark Plan برای Cloud Storage for Firebase فراتر بروم؟
هنگامی که شما بیش از محدودیت های Cloud Storage در یک پروژه در برنامه Spark هستید ، نتیجه به نوع محدودیتی که بیش از آن است بستگی دارد:
اگر از حد ذخیره شده GB فراتر بروید ، نمی توانید داده های بیشتری را در آن پروژه ذخیره کنید ، مگر اینکه برخی از داده های ذخیره شده یا به روزرسانی را به طرحی که فضای ذخیره سازی بیشتری یا فضای ذخیره سازی نامحدود را فراهم می کند ، حذف کنید.
اگر از حد بارگیری GB فراتر بروید ، برنامه شما تا روز بعد قادر به بارگیری داده های بیشتر نخواهد بود (از نیمه شب ، زمان اقیانوس آرام ایالات متحده) ، مگر اینکه به طرحی با محدودیت های محدود کننده کمتر یا بدون محدودیت ارتقا دهید.
اگر بیش از حد مجاز عملیات بارگذاری یا بارگیری باشید ، برنامه شما قادر نخواهد بود تا روز بعد داده های بیشتری را بارگذاری یا بارگیری کنید (از نیمه شب ، زمان اقیانوس آرام ایالات متحده) ، مگر محدودیت ها
حریم خصوصی
از کجا می توانم اطلاعاتی در مورد حریم خصوصی و امنیت در Firebase پیدا کنم؟
آیا SDK های Firebase اطلاعات استفاده/تشخیصی را در خارج از تجزیه و تحلیل وارد می کنند؟
بله. این در حال حاضر فقط iOS است ، اما ممکن است در آینده تغییر کند. Firebase Apple Platforms SDK به طور پیش فرض شامل چارچوب FirebaseCoreDiagnostics است. این چارچوب توسط Firebase برای جمع آوری اطلاعات استفاده و تشخیص SDK برای کمک به اولویت بندی پیشرفت های آینده محصول استفاده می شود. FirebaseCoreDiagnostics اختیاری است ، بنابراین اگر می خواهید از ارسال سیاهههای تشخیصی Firebase خودداری کنید ، می توانید این کار را با جدا کردن کتابخانه از برنامه خود انجام دهید. می توانید منبع کامل ، از جمله مقادیر ورود به سیستم را در GitHub مرور کنید
A/B Testing
A/B Testing : چند آزمایش را می توانم ایجاد کنم و اجرا کنم؟
به شما اجازه داده می شود تا 300 آزمایش در هر پروژه ، که می تواند شامل 24 آزمایش در حال اجرا باشد ، با بقیه به عنوان پیش نویس یا تکمیل شده باشد.
A/B Testing : چرا نمی توانم آزمایشات خود را بعد از تركیب و پیوند مجدد پروژه خود به Google Analytics مشاهده كنم؟
پیوند دادن به یک ویژگی مختلف Google Analytics باعث می شود شما دسترسی به آزمایش های ایجاد شده از قبل را از دست دهید. برای بازیابی مجدد دسترسی به یک آزمایش قبلی ، دوباره پروژه خود را به ویژگی Google Analytics که هنگام ایجاد آزمایش مرتبط بود ، دوباره پیوند دهید.
A/B Testing : چرا هنگام ایجاد یک آزمایش پیکربندی از راه دور ، یک پیام "پروژه ای که به Google Analytics مرتبط نیست" دریافت می کنم؟
اگر قبلاً Firebase و Google Analytics را پیوند داده اید ، اما هنوز هم پیامی را مشاهده می کنید که Google Analytics به هم پیوند ندارد ، اطمینان حاصل کنید که یک جریان تحلیلی برای همه برنامه های پروژه شما وجود دارد. در حال حاضر ، تمام برنامه های یک پروژه باید برای استفاده از آزمایش A/B به یک جریان Google Analytics متصل شوند.
شما می توانید لیست کلیه جریان های فعال را در صفحه جزئیات ادغام Google Analytics در کنسول Firebase ، دسترسی به settingsپروژهتنظیماتchevron_rightchevron_rightGoogle Analyticschevron_rightمدیریت کنید .
ایجاد یک جریان Google Analytics برای هر برنامه ای که یک برنامه ندارد باید مسئله را حل کند. چند روش برای ایجاد جریان برای برنامه های گمشده وجود دارد:
اگر فقط یک یا دو برنامه دارید که یک جریان مرتبط با Google Analytics را از دست داده اید ، می توانید یکی از روش های زیر را برای اضافه کردن یک جریان Google Analytics انتخاب کنید:
هر برنامه را بدون جریان فعال در کنسول Firebase حذف و دوباره اضافه کنید.
از کنسول Google Analytics ، Admin را انتخاب کنید ، روی Data Streams کلیک کنید ، سپس روی افزودن جریان ، اضافه کردن جزئیات برنامه گمشده ، کلیک کنید و روی برنامه Register کلیک کنید.
اگر بیش از چند جریان برنامه گمشده دارید ، ویژگی های تبلیغاتی Google Analytics سریعترین و کارآمدترین روش برای ایجاد جریان برنامه های گمشده است:
از settingsتنظیمات پروژه ، ادغام ها را انتخاب کنید.
در کارت Google Analytics ، روی مدیریت برای دسترسی به تنظیمات Firebase و Google Analytics کلیک کنید.
یادداشتی از شناسه خاصیت Google Analytics و حساب Google Analytics Linked یادداشت کنید.
more_vertMore را کلیک کنید و از این پروژه unlink Analytics را انتخاب کنید.
هشداری را که ظاهر می شود را مرور کنید (در اینجا نگران نباشید ؛ در مرحله بعدی همان ویژگی را خواهید دید) ، سپس روی Unlink Google Analytics کلیک کنید.
با اتمام کار ، به صفحه ادغام هدایت می شوید.
در کارت Google Analytics ، برای شروع روند اتصال ، روی Enable کلیک کنید.
حساب Analytics خود را از لیست حساب انتخاب کنید.
در کنار ایجاد خودکار یک ویژگی جدید در این حساب ، روی editویرایش کلیک کنید و از لیست املاک Analytics که ظاهر می شود ، شناسه ویژگی خود را انتخاب کنید.
لیستی از همه برنامه های پروژه شما ظاهر می شود. نگاشتهای جریان موجود برای هر برنامه ذکر شده است و برنامه هایی که جریان ندارند ، یک مورد برای آنها ایجاد می کنند.
روی Enable Google Analytics کلیک کنید تا از ویژگی های خاص استفاده کنید.
AdMob : آیا می توانم برنامه های ویندوز خود را به Firebase پیوند دهم؟
نه ، برنامه های ویندوز در حال حاضر پشتیبانی نمی شوند.
AdMob : چرا نمی توانم برنامه خود را به AdMob از کنسول Firebase پیوند دهم؟
می توانید یک برنامه AdMob را از طریق کنسول AdMob به یک برنامه Firebase پیوند دهید. یاد بگیرید چگونه.
AdMob : برای پیوند یک برنامه Firebase به یک برنامه AdMob ، چه مجوزها یا دسترسی لازم را دارم؟
برای انجام این پیوند ، به دسترسی زیر نیاز دارید:
AdMob : شما باید یک مدیر AdMob باشید.
Firebase : شما باید مجوز firebase.links.create را داشته باشید ، که در نقش مالک و نقش مدیر Firebase گنجانده شده است.
Google Analytics : شما باید نقش ویرایش را داشته باشید یا نقش کاربران را برای ویژگی مرتبط با پروژه Firebase مدیریت کنید. بیشتر بدانید.
AdMob : آیا چندین کاربر در همان برنامه AdMob LINK LINK AdMob برنامه ها و برنامه های Firebase می توانند؟
برای حساب های AdMob چند کاربره ، کاربری که اولین لینک Firebase را ایجاد کرده و شرایط سرویس Firebase را پذیرفته است ، تنها کاربری است که می تواند پیوندهای جدیدی بین برنامه های AdMob و برنامه های Firebase ایجاد کند.
AdMob : برای استفاده از AdMob ، از کدام SDK ها باید استفاده کنم؟
برای استفاده از AdMob ، همیشه از Google Mobile Ads SDK همانطور که در این سؤالات متداول توضیح داده شده است ، استفاده کنید. علاوه بر این و به صورت اختیاری ، اگر می خواهید معیارهای کاربر را برای AdMob جمع کنید ، سپس Firebase SDK را برای Google Analytics در برنامه خود درج کنید.
برای پروژه های اندرویدی : وابستگی Google Mobile Ads SDK را به پرونده build.gradle خود اضافه کنید: implementation 'com.google.android.gms:play-services-ads:23.3.0'
Analytics : چرا Google Analytics بخشی توصیه شده از استفاده از محصولات Firebase است؟
Google Analytics یک راه حل تجزیه و تحلیل رایگان و نامحدود است که با ویژگی های Firebase برای ارائه بینش های قدرتمند کار می کند. این امکان را به شما می دهد تا گزارش های رویداد را در Crashlytics ، اثربخشی اعلان در FCM ، عملکرد عمیق پیوند برای Dynamic Links و داده های خرید درون برنامه از Google Play مشاهده کنید. این قدرت مخاطبان پیشرفته را در Remote Config ، شخصی سازی Remote Config و موارد دیگر هدف قرار می دهد.
Google Analytics به عنوان لایه ای از اطلاعات در کنسول Firebase عمل می کند تا بینش های عملی تری در مورد نحوه توسعه یک برنامه با کیفیت بالا ، رشد پایگاه کاربر خود و کسب درآمد بیشتر به شما ارائه دهد.
Analytics : چگونه می توانم چگونگی به اشتراک گذاشتن داده های Analytics من با بقیه Firebase را کنترل کنم؟
به طور پیش فرض ، از داده های Google Analytics شما برای تقویت سایر ویژگی های Firebase و Google استفاده می شود. شما می توانید نحوه اشتراک داده های Google Analytics خود را در تنظیمات پروژه خود در هر زمان کنترل کنید. در مورد تنظیمات به اشتراک گذاری داده ها بیشتر بدانید.
Analytics : چگونه می توانم تنظیمات ویژگی های Analytics خود را به روز کنم؟
از صفحه سرپرست موجود در ویژگی Google Analytics ، می توانید تنظیمات املاک خود را به روز کنید ، مانند:
تنظیمات اشتراک داده
تنظیمات حفظ داده ها
تنظیمات منطقه زمانی و ارز
برای به روزرسانی تنظیمات املاک خود ، این مراحل را دنبال کنید:
در کنسول Firebase ، به settings خود> تنظیمات پروژه بروید.
به برگه Integrations بروید ، و سپس در کارت Google Analytics ، روی مدیریت یا مشاهده پیوند کلیک کنید.
Analytics : چرا من پس از جدا کردن Firebase از Google Analytics ، هیچ اطلاعات Analytics در کنسول Firebase نمی بینم؟
داده های Analytics در ویژگی Google Analytics - نه در پروژه Firebase قرار دارند. اگر خاصیت را حذف یا حذف کنید ، داده های Analytics برای Firebase قابل دسترسی نخواهند بود و یک داشبورد Analytics خالی را در کنسول Firebase مشاهده خواهید کرد. توجه داشته باشید که از آنجا که داده ها هنوز در ویژگی قبلی مرتبط هستند ، همیشه می توانید ویژگی را به Firebase متصل کرده و داده های Analytics را در کنسول Firebase مشاهده کنید.
پیوند دادن یک حساب جدید Google Analytics (و بنابراین یک ویژگی جدید Google Analytics) به پروژه Firebase شما منجر به داشبورد خالی Analytics در کنسول Firebase خواهد شد. با این حال ، اگر خاصیت قبلاً مرتبط شما وجود دارد ، می توانید داده های موجود را از ملک قدیمی به ویژگی جدید منتقل کنید.
Analytics : اگر خاصیت Analytics من و داده های آن حذف شده است ، آیا راهی برای بازگرداندن آنها وجود دارد؟
نه. اگر ملک شما حذف شده است ، امکان حذف این ملک یا بازیابی داده های Analytics قبلاً جمع آوری شده در آن ویژگی امکان پذیر نیست.
اگر می خواهید دوباره استفاده از Google Analytics را شروع کنید ، می توانید یک ویژگی جدید یا یک ملک موجود را به پروژه Firebase خود پیوند دهید. شما می توانید این پیوند را در کنسول Firebase یا UI Google Analytics انجام دهید. در مورد پیوند یک ویژگی Google Analytics به پروژه Firebase خود بیشتر بدانید.
Analytics : اگر خاصیت Analytics من حذف شد ، آیا می توانم یک ویژگی جدید Google Analytics را به پروژه Firebase خود پیوند دهم و دوباره از Analytics استفاده کنم؟
اگر می خواهید دوباره استفاده از Google Analytics را شروع کنید ، می توانید یک ویژگی جدید یا یک ملک موجود را به پروژه Firebase خود پیوند دهید. شما می توانید این پیوند را در کنسول Firebase یا UI Google Analytics انجام دهید. در مورد پیوند یک ویژگی Google Analytics به پروژه Firebase خود بیشتر بدانید.
توجه داشته باشید که از آنجا که تمام داده های Analytics در این ملک ذخیره می شوند (نه پروژه Firebase) ، داده های Analytics قبلاً جمع آوری شده را نمی توان بازیابی کرد.
Analytics : چگونه محصولات Firebase یا محصولات یکپارچه Google تحت تأثیر حذف ویژگی Analytics من قرار می گیرند؟
چندین محصول Firebase به ادغام Google Analytics متکی هستند. اگر خاصیت Analytics و داده های آن حذف شده است ، در صورت استفاده از محصولات زیر ، موارد زیر اتفاق می افتد:
Crashlytics دیگر نمی توانید کاربران بدون تصادف ، سیاهههای مربوط به آرد و یا هشدارهای سرعت را ببینید.
Cloud Messaging و In-App Messaging -دیگر نمی توانید از هدف قرار دادن ، معیارهای کمپین ، تقسیم مخاطبان و برچسب های تحلیلی استفاده کنید.
Remote Config - دیگر نمی توانید از پیکربندی های هدفمند یا شخصی سازی استفاده کنید.
A/B Testing - شما دیگر نمی توانید از A/B Testing استفاده کنید زیرا اندازه گیری آزمایش توسط Google Analytics ارائه می شود.
Dynamic Links - هر ویژگی متکی به داده های Google Analytics مختل می شود.
علاوه بر این ، ادغام های زیر تحت تأثیر قرار می گیرد:
Analytics : چگونه می توانم کاربرانی را که معیار را رعایت نکرده اند ، تقسیم کنم؟
شما می توانید با "هدف قرار دادن منفی" این کاربران ، این مشکل را تغییر دهید. به عنوان مثال ، این مشکل را به عنوان "به افرادی که چیزی خریداری کرده اند" نشان ندهید ، و مخاطبان آن کاربران را برای هدف قرار دادن تشکیل دهید.
Analytics : آیا مخاطبان و/یا رویدادها در رابط Google Analytics در کنسول Firebase نیز تعریف شده اند؟
مخاطبان و خصوصیات کاربر شما همگام می شوند. برای برخی از ویژگی ها ، باید از رابط Google Analytics مانند تقسیم بندی و قیف های بسته استفاده کنید. شما می توانید به طور مستقیم از طریق پیوندهای عمیق از کنسول Firebase به رابط Google Analytics دسترسی پیدا کنید.
هر تغییری که از کنسول Firebase ایجاد می کنید نیز می تواند در Google Analytics انجام شود و این تغییرات در Firebase منعکس می شود.
Authentication
Firebase Authentication : از کدام مناطق برای احراز هویت تلفن پشتیبانی می شود؟
Firebase Authentication از تأیید شماره تلفن در سطح جهان پشتیبانی می کند ، اما همه شبکه ها با اطمینان پیام های تأیید را ارائه نمی دهند. مناطق زیر نرخ تحویل خوبی دارند و انتظار می رود که برای تأیید اعتبار تلفن خوب کار کند. در جایی که ذکر شد ، برخی از حامل ها به دلیل ضعیف موفقیت در تحویل در منطقه در دسترس نیستند.
منطقه
کد
پس از میلاد
آندورا
AE
امارات متحده عربی
AF
افغانستان
AG
آنتیگوا و باربودا
AL
آلبانی
AM
ارمنستان
AO
آنگولا
AR
آرژانتین
AS
ساموآی آمریکایی
AT
اتریش
AU
استرالیا
AW
آروبا
AZ
آذربایجان
BA
بوسنی و هرزگوین
BB
باربادوس
BD
بنگلادش
BE
بلژیک
BF
بورکینافاسو
BG
بلغارستان
بی جی
بنین
BM
برمودا
BN
برونئی دارالسلام
BO
بولیوی
BR
برزیل
BS
باهاما
BT
بوتان
BW
بوتسوانا
توسط
بلاروس
BZ
بلیز
CA
کانادا
سی دی
کنگو، (کینشاسا)
CF
جمهوری آفریقای مرکزی
CG
کنگو (برازاویل)
CH
سوئیس
CI
ساحل عاج
CK
جزایر کوک
CL
شیلی
سی ام
کامرون
CO
کلمبیا
CR
کاستاریکا
CV
کیپ ورد
CW
کوراسائو
CY
قبرس
CZ
جمهوری چک
DE
آلمان
دی جی
جیبوتی
DK
دانمارک
DM
دومینیکا
انجام دهید
جمهوری دومینیکن
DZ
الجزایر
EC
اکوادور
EG
مصر
ES
اسپانیا
ET
اتیوپی
FI
فنلاند
اف جی
فیجی
FK
جزایر فالکلند (مالویناس)
FM
میکرونزی، ایالات فدرال
FO
جزایر فارو
FR
فرانسه
GA
گابن
گیگابایت
انگلستان
جی دی
گرانادا
جنرال الکتریک
گرجستان
GF
گویان فرانسه
جی جی
گرنزی
GH
غنا
GI
جبل الطارق
GL
گرینلند
جنرال موتورز
گامبیا
GP
گوادلوپ
GQ
گینه استوایی
GR
یونان
GT
گواتمالا
GY
گویان
HK
هنگ کنگ، SAR چین
HN
هندوراس
منابع انسانی
کرواسی
HT
هائیتی
HU
مجارستان
شناسه
اندونزی
IE
ایرلند
IL
اسرائیل
IM
جزیره من
در
هند
IQ
عراق
IT
ایتالیا
JE
جرسی
JM
جامائیکا
JO
اردن
JP
ژاپن
KE
کنیا
KG
قرقیزستان
KH
کامبوج
KM
کومور
KN
سنت کیتس و نویس
KR
کره (جنوبی)
KW
کویت
KY
جزایر کیمن
KZ
قزاقستان
لس آنجلس
لائوس PDR
LB
لبنان
LC
سنت لوسیا
LI
لیختن اشتاین
LK
سریلانکا
LS
لسوتو
آن
لیتوانی
LU
لوکزامبورگ
LV
لتونی
LY
لیبی
MA
مراکش
MD
مولداوی
من
مونته نگرو
MF
سن مارتین (بخش فرانسوی)
ام جی
ماداگاسکار
MK
مقدونیه، جمهوری
MM
میانمار
MN
مغولستان
MO
ماکائو، SAR چین
اماس
مونتسرات
MT
مالت
MU
موریس
مگاوات
مالاوی
MX
مکزیک
من
مالزی
MZ
موزامبیک
NA
نامیبیا
NC
کالدونیای جدید
NE
نیجر
NF
جزیره نورفولک
NG
نیجریه
NI
نیکاراگوئه
NL
هلند
نه
نروژ
NP
نپال
NZ
نیوزلند
OM
عمان
PA
پاناما
PE
پرو
PG
پاپوآ گینه نو
PH
فیلیپین
PK
پاکستان
PL
لهستان
PM
سنت پیر و میکلون
روابط عمومی
پورتوریکو
PS
سرزمین فلسطین
PT
پرتغال
PY
پاراگوئه
QA
قطر
RE
رئونیون
RO
رومانی
RS
صربستان
RU
فدراسیون روسیه
RW
رواندا
SA
عربستان سعودی
SC
سیشل
SE
سوئد
SG
سنگاپور
SH
سنت هلنا
SI
اسلوونی
SK
اسلواکی
SL
سیرالئون
SN
سنگال
SR
سورینام
ST
سائوتومه و پرنسیپ
SV
السالوادور
SZ
سوازیلند
TC
جزایر تورکس و کایکوس
TG
توگو
TH
تایلند
TL
تیمور شرقی
TM
ترکمنستان
به
تونگا
TR
ترکیه
TT
ترینیداد و توباگو
TW
تایوان، جمهوری چین
TZ
تانزانیا، جمهوری متحده
UA
اوکراین
UG
اوگاندا
ایالات متحده
ایالات متحده آمریکا
UY
اروگوئه
UZ
ازبکستان
VC
سنت وینسنت و گرنادین
VE
ونزوئلا (جمهوری بولیوار)
VG
جزایر ویرجین بریتانیا
VI
جزایر ویرجین، ایالات متحده
VN
ویتنام
WS
ساموآ
بله
یمن
YT
مایوت
ZA
آفریقای جنوبی
ZM
زامبیا
ZW
زیمبابوه
Firebase Authentication : چگونه می توانم هنگام استفاده از احراز هویت تلفن از سوء استفاده از پیام کوتاه جلوگیری کنم؟
برای کمک به محافظت از پروژه خود در برابر پمپاژ ترافیک پیام کوتاه و سوءاستفاده API ، مراحل زیر را بردارید:
در نظر بگیرید که خط مشی منطقه پیام کوتاه را تعیین کنید
به دنبال مناطقی با تعداد بسیار بالا پیام کوتاه و تعداد بسیار کمی (یا صفر) پیامک های تأیید شده باشید. نسبت تأیید شده/ارسال شده میزان موفقیت شماست. میزان موفقیت سالم معمولاً در محدوده 70-85 ٪ است زیرا پیامک یک پروتکل تحویل تضمین شده نیست و برخی از مناطق ممکن است سوءاستفاده را تجربه کنند. نرخ موفقیت زیر 50 ٪ حاکی از بسیاری از پیامک های ارسال شده اما تعداد کمی از ورود به سیستم موفقیت آمیز است که این یک نشانگر رایج بازیگران بد و پمپاژ ترافیک پیام کوتاه است.
از خط مشی منطقه SMS برای انکار مناطق پیام کوتاه با نرخ موفقیت پایین استفاده کنید ، یا فقط در صورتی که برنامه شما فقط برای توزیع در بازارهای خاص در نظر گرفته شده باشد ، به مناطق خاصی اجازه می دهید.
دامنه های احراز هویت مجاز خود را محدود کنید
برای مدیریت دامنه های مجاز از داشبورد تنظیمات احراز هویت استفاده کنید. دامنه localhost به طور پیش فرض به دامنه های تأیید هویت تأیید شده برای ساده سازی توسعه اضافه می شود. در نظر بگیرید که localhost از حوزه های مجاز در پروژه تولید خود حذف کنید تا از بازیگران بد برای دسترسی به پروژه localhostخود جلوگیری کنید تا به پروژه تولید خود دسترسی پیدا کنید.
بررسی برنامه را فعال و اجرا کنید
با تأیید اینکه درخواست ها فقط از برنامه های مرتبط با پروژه شما هستند ، برنامه را برای محافظت از پروژه خود در برابر سوءاستفاده API فعال کنید.
به یاد داشته باشید که شما باید برای تأیید اعتبار در کنسول Firebase ، تأیید برنامه را اجرا کنید (قبل از اجرای آن نظارت بر ترافیک را در نظر بگیرید). همچنین ، لیست سایتهای تأیید شده RecAptcha Enterprise خود را دوبار بررسی کنید تا تأیید کنید که فقط شامل سایت های تولید شما است و لیست برنامه های ثبت شده در پروژه شما در بررسی برنامه دقیق است.
توجه داشته باشید که بررسی برنامه با ادعا اینکه این تماس از یکی از برنامه های ثبت شده شما انجام می شود ، به محافظت در برابر حملات خودکار کمک می کند. این مانع از استفاده کاربران از برنامه شما به روش های ناخواسته نمی شود (به عنوان مثال ، شروع نمی شود و هرگز جریان ورود به سیستم را برای تولید پیامک ارسال شده انجام نمی دهد).
Firebase Authentication : آیا شماره تلفن ها به یک شرکت مخابراتی جدید از طریق تأیید اعتبار تلفن منتقل می شوند؟
در این زمان ، شماره های منتقل شده بین حامل ها باعث می شود که تمام پیامک ها برای آن کاربران نهایی غیرقابل تحمل شوند. هیچ راه حل وجود ندارد و Firebase در حال کار بر روی این مسئله است.
Firebase Authentication : در برنامه Android من ، چرا خطای زیر را دریافت می کنم: Google sign in failed ؟
اگر خطای زیر را دریافت می کنید ، مراحل عیب یابی را در این سؤالات متداول دنبال کنید:
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)
اطمینان حاصل کنید که ورود به سیستم Google به درستی به عنوان ارائه دهنده احراز هویت فعال شده است:
در برگه Sign In Method ، روش ورود به سیستم Google (حتی اگر قبلاً فعال باشد) را غیرفعال کرده و دوباره فعال کنید:
روش ورود به سیستم Google را باز کنید ، آن را غیرفعال کنید و سپس روی ذخیره کلیک کنید.
روش ورود به سیستم Google را دوباره باز کنید ، آن را فعال کنید و سپس روی ذخیره کلیک کنید.
همچنین ، در پیکربندی ارائه دهنده ورود به سیستم Google از بخش Authentication ، اطمینان حاصل کنید که شناسه مشتری OAUTH و مخفی با مشتری وب نمایش داده شده در صفحه اعتبار کنسول Google Cloud مطابقت دارد (به بخش IDS مشتری OAUTH 2.0 نگاه کنید).
Firebase Authentication : در برنامه وب من ، چرا با خطای زیر وارد سیستم می شوند: This domain YOUR_REDIRECT_DOMAIN is not authorized to run this operation ؟
اگر خطای زیر را دریافت می کنید ، مراحل عیب یابی را در این سؤالات متداول دنبال کنید:
This domain YOUR_REDIRECT_DOMAIN is not authorized to run this operation.
این خطا به احتمال زیاد ایجاد می شود زیرا دامنه تغییر مسیر شما به عنوان یک دامنه مجاز برای Firebase Authentication ذکر نشده است ، یا کلید API که شما با سرویس Firebase Authentication استفاده می کنید نامعتبر است.
ابتدا اطمینان حاصل کنید که YOUR_REDIRECT_DOMAIN در لیست دامنه های مجاز برای پروژه Firebase شما قرار دارد. اگر دامنه تغییر مسیر شما قبلاً در آنجا ذکر شده است ، همچنان یک کلید API نامعتبر را عیب یابی کنید.
به طور پیش فرض ، Firebase Authentication JS SDK برای پروژه Firebase شما که به عنوان Browser key شناخته شده است ، به کلید API متکی است و از این کلید برای تأیید اینکه یک URL تغییر مسیر ورود به سیستم با توجه به لیست دامنه های مجاز معتبر است ، استفاده می کند. Authentication این کلید API را بسته به نحوه دسترسی به Authentication SDK دریافت می کند:
اگر از یاران Auth با ارائه Hosting برای ورود به سیستم با Authentication JS SDK استفاده می کنید ، پس Firebase به طور خودکار کلید API خود را با بقیه پیکربندی Firebase خود هر بار که به Firebase Hosting اعزام می کنید ، به دست می آورد. اطمینان حاصل کنید که authDomain در برنامه وب شما firebaseConfigبه درستی پیکربندی شده است تا از یکی از دامنه ها برای آن سایت Hosting استفاده کند. شما می توانید این موضوع را با مراجعه به https:// authDomain __/firebase/init.json تأیید کنید ، و بررسی کنید که این projectId از firebaseConfig شما مطابقت دارد.
اگر کد ورود به سیستم خود را میزبان می کنید ، می توانید از یک پرونده __/firebase/init.json استفاده کنید تا پیکربندی Firebase را به Authentication خود میزبان JS SDK تغییر دهید. کلید API و projectId ذکر شده در این پرونده پیکربندی باید با برنامه وب firebaseConfig شما مطابقت داشته باشد.
بررسی کنید تا مطمئن شوید این کلید API حذف نشده است: به پانل APIS & Services> Crectentials در کنسول Google Cloud بروید که در آن تمام کلیدهای API برای پروژه شما ذکر شده است.
اگر Browser key حذف نشده است ، موارد زیر را بررسی کنید:
اگر کد ورود به سیستم خود را میزبان می کنید ، مطمئن شوید که کلید API ذکر شده در پرونده __/firebase/init.json با کلید API در کنسول ابر مطابقت دارد. در صورت لزوم کلید موجود در پرونده را اصلاح کنید ، سپس برنامه خود را مجدداً مجدداً مستقر کنید.
اگر Browser key حذف شده است ، می توانید Firebase یک کلید جدید API را برای شما ایجاد کنید: در کنسول Firebase ، به settings > تنظیمات پروژه بروید ، سپس در بخش برنامه های خود ، روی برنامه وب خود کلیک کنید. این عمل به طور خودکار یک کلید API را ایجاد می کند که می توانید در بخش تنظیمات و پیکربندی SDK برای برنامه وب خود مشاهده کنید.
توجه داشته باشید که در کنسول ابر ، این کلید جدید API به عنوان Browser key نامیده نمی شود. در عوض ، این نام مستعار برنامه وب Firebase شما خواهد بود. اگر تصمیم دارید محدودیت های API را به این کلید جدید API اضافه کنید ، اطمینان حاصل کنید که API Firebase Authentication در لیست API های مجاز قرار دارد.
پس از ایجاد کلید جدید API ، مراحل قابل اجرا را در زیر انجام دهید:
اگر از URL های Hosting رزرو شده استفاده می کنید ، سپس برنامه خود را به Firebase دوباره مستقر کنید تا بتواند به طور خودکار کلید API جدید را با بقیه پیکربندی Firebase خود بدست آورد.
اگر از کد ورود به سیستم خودداری می کنید ، کلید جدید API را کپی کرده و آن را به پرونده __/firebase/init.json خود اضافه کنید ، سپس برنامه خود را دوباره مستقر کنید.
Firebase Authentication : چگونه می توانم یک مشتری وب OAuth را به صورت دستی بسازم ؟؟
در برگه Sign In Method ، ارائه دهنده ورود به سیستم Google را باز کنید ، و سپس شناسه مشتری وب سرور و راز را که فقط از کنسول Google Cloud ساخته و کپی کرده اید ، جایگذاری کنید. روی ذخیره کلیک کنید.
Firebase Authentication :%APP_NAME% برای الگوی ایمیل برای ایمیل تأیید که می تواند هنگام ثبت نام با استفاده از آدرس ایمیل و رمز عبور برای کاربر ارسال شود ، تعیین می شود؟
قبل از دسامبر سال 2022 ، %APP_NAME% در الگوی ایمیل با نام تجاری OAuth که به طور خودکار تهیه می شد هر زمان که یک برنامه Android در پروژه Firebase ثبت شده بود ، جمع می شد. اکنون ، از آنجا که مارک OAuth فقط در صورت فعال بودن ورود به سیستم Google ارائه می شود ، در زیر توضیح می دهد که چگونه %APP_NAME% مشخص می شود:
اگر نام تجاری OAUTH در دسترس باشد ، %APP_NAME% در الگوی ایمیل نام تجاری OAuth (مشابه رفتار قبل از دسامبر 2022) خواهد بود.
اگر نام تجاری OAUTH در دسترس نیست ، در اینجا چگونه %APP_NAME% در الگوی ایمیل مشخص می شود:
For web apps , the %APP_NAME% will be the default Firebase Hosting site name (the value preceding .firebaseapp.com and .web.app and usually the Firebase project ID).
For mobile apps:
If the Android package name or iOS bundle ID is present in the request, then the %APP_NAME% will be the app name used in the Play Store or App Store (respectively).
Otherwise, the %APP_NAME% will be the default Firebase Hosting site name (the value preceding .firebaseapp.com and .web.app and usually the Firebase project ID).
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
Cloud Functions runtime support
How do I upgrade to the latest supported version of Node.js?
How can I make sure I deployed my functions to a specific Node.js runtime?
In the Firebase console, go to the functions dashboard , select a function, and check the function's language under Additional details .
I use Firebase Extensions. Will I be affected by Cloud Functions runtime updates?
بله. Since extensions use Cloud Functions , the runtime of your extensions will need to be updated on the same timeline as Cloud Functions.
We recommend that you periodically update to the latest version of each extension installed in your project. You can upgrade your projects' extensions via the Firebase console or Firebase CLI .
Cloud Messaging
Cloud Messaging : What's the difference between the Notifications composer and Cloud Messaging ?
Firebase Cloud Messaging provides a complete set of messaging capabilities through its client SDKs and HTTP and XMPP server protocols. For deployments with more complex messaging requirements, FCM is the right choice.
The Notifications composer is a lightweight, serverless messaging solution built on Firebase Cloud Messaging . With a user-friendly graphical console and reduced coding requirements, the Notifications composer lets users easily send messages to reengage and retain users, foster app growth, and support marketing campaigns.
قابلیت ها
Notifications composer
Cloud Messaging
هدف
Single device
Clients subscribed to topics (ie weather)
Clients in predefined user segment (app, version, language)
Clients in specified analytics audiences
Clients in device groups
Upstream from client to server
نوع پیام
Notifications up to 2kb
Data messages up to 4kb
تحویل
فوری
Future client device local time
تجزیه و تحلیل
Built-in Notifications analytics collection and funnel analytics
Cloud Messaging : Apple announced they're deprecating the legacy binary protocol for APNs. آیا لازم است کاری انجام دهم؟
No. Firebase Cloud Messaging switched to the HTTP/2-based APNs protocol in 2017. If you are using FCM to send notifications to iOS devices, there should be no action required on your part.
Cloud Messaging : Do I need to use other Firebase services in order to use FCM ?
You can use Firebase Cloud Messaging as a standalone component, in the same manner as you did with GCM, without using other Firebase services.
Cloud Messaging : I am an existing Google Cloud Messaging (GCM) developer. Should I move to Firebase Cloud Messaging ?
FCM is the new version of GCM under the Firebase brand. It inherits GCM's core infrastructure, with new SDKs to make Cloud Messaging development easier.
Benefits of upgrading to FCM SDK include:
Simpler client development. You no longer have to write your own registration or subscription retry logic.
An out-of-the-box notification solution. You can use the Notifications composer, a serverless notifications solution with a web console that lets anyone send notifications to target specific audiences based on insights from Google Analytics.
To upgrade from GCM SDKs to FCM SDKs, see the guides for migrating Android and iOS apps.
Cloud Messaging : Why do my targeted devices apparently fail to receive messages?
When it looks like devices haven't successfully received messages, check first for these two potential causes:
Foreground message handling for notification messages . Client apps need to add message handling logic to handle notification messages when the app is in the foreground on the device. See the details for iOS and Android .
Network firewall restrictions . If your organization has a firewall that restricts the traffic to or from the Internet, you need to configure it to allow connectivity with FCM in order for your Firebase Cloud Messaging client apps to receive messages. The ports to open are:
5228
5229
5230
FCM usually uses 5228, but it sometimes uses 5229 and 5230. FCM does not provide specific IPs, so you should allow your firewall to accept outgoing connections to all IP addresses contained in the IP blocks listed in Google's ASN of 15169 .
Cloud Messaging : I have implemented onMessageReceived in my Android app, but it is not being called.
When your app is in the background, notification messages are displayed in the system tray, and onMessageReceived is not called. For notification messages with a data payload, the notification message is displayed in the system tray, and the data that was included with the notification message can be retrieved from the intent launched when the user taps on the notification.
Notifications composer: What's the difference between the Notifications composer and Cloud Messaging ?
The Notifications composer is a lightweight, serverless messaging solution built on Firebase Cloud Messaging . With a user-friendly graphical console and reduced coding requirements, the Notifications composer lets users easily send messages to reengage and retain users, foster app growth, and support marketing campaigns.
Firebase Cloud Messaging provides a complete set of messaging capabilities through its client SDKs and HTTP and XMPP server protocols. For deployments with more complex messaging requirements, FCM is the right choice.
Here's a comparison of the messaging capabilities provided by Firebase Cloud Messaging and the Notifications composer:
قابلیت ها
Notifications composer
Cloud Messaging
هدف
Single device
Clients subscribed to topics (ie weather)
Clients in predefined user segment (app, version, language)
Clients in specified analytics audiences
Clients in device groups
Upstream from client to server
نوع پیام
Notifications up to 2kb
Data messages up to 4kb
تحویل
فوری
Future client device local time
تجزیه و تحلیل
Built-in Notifications analytics collection and funnel analytics
Notifications composer: I am an existing Google Cloud Messaging (GCM) developer, and I want to use the Notifications composer. چه کار کنم؟
The Notifications composer is an out-of-the-box solution that lets anyone send notifications to target specific audiences based on insights from Google Analytics. Also, the Notifications composer provides funnel analysis for every message, allowing easy evaluation of notification effectiveness.
If you are an existing GCM developer, to use the Notifications composer you have to upgrade from GCM SDKs to FCM SDKs. See the guides for migrating Android and iOS apps.
FCM features deprecated in June 2023
Which FCM APIs were deprecated on June 20, 2023, and what should I do if I am using those APIs?
The following APIs/SDKs will be affected by the deprecation:
Server APIs
نام API
نقطه پایانی API
Impact on users
اقدام لازم است
Legacy HTTP protocol
https://fcm.googleapis.com/fcm/send
Requests to the endpoint will start failing after 6/21/2024.
API calls to FirebaseMessaging.send in the app won't trigger upstream messages to the app server after 6/21/2024.
Implement this functionality in your server logic. For example, some developers implement their own HTTP/gRPC endpoint and call the endpoint directly to send messages from their clients to the app server. See this gRPC Quick start for an example implementation of upstream messaging using gRPC.
Batch Send API
https://fcm.googleapis.com/batch
Requests to the endpoint will start failing after 6/21/2024.
These APIs will stop working after 6/21/2024 because they call the batch send API .
Upgrade to the latest Firebase Admin SDK and use the new APIs instead: sendEach()/ sendEachAsync()/send_each()/sendEachForMulticast()/sendEachForMulticastAsync()/ send_each_for_multicast() .
Note that the new APIs no longer call the deprecated batch send API, and for this reason they may create more concurrent HTTP connections than the old APIs.
Client SDKs
SDK versions
Impact on users
اقدام لازم است
GCM SDKs (deprecated in 2018)
Apps using GCM SDKs will not be able to register tokens nor receive messages from FCM after 6/21/2024.
Upgrade your Android SDK to the latest Firebase SDK if you haven't already done so.
JS SDKs version <7.0.0 (breaking change at version 7.0.0 in 2019)
Web apps using older JS SDKs will not be able to register tokens after 6/21/2024.
Upgrade your Firebase Web SDK to the latest version.
Will I see a service downgrade before June 2024?
No. You have 12 months (06/20/2023 - 06/21/2024) to migrate from the old APIs to new APIs without any service downgrade. We strongly recommend you to plan the migration as early as possible so you won't be impacted by the decommissioning of the APIs in June 2024.
After June 2024, you may see increased errors or lack of functionality when using the APIs/SDKs listed above (see the next FAQ for more information).
How and when will the deprecated APIs be shut down?
FCM will start a gradual shutdown of deprecated APIs around July 22nd, 2024. After this date, deprecated services will be subject to a "flickering" process in which increasing numbers of requests will return error responses. During the gradual ramp-down period you can expect the following behavior and error responses to increase in frequency over time:
دسته بندی
انتظار چه چیزی
Legacy HTTP protocol
Requests being rejected with HTTP code 301.
Legacy XMPP protocol
Requests being rejected with error code 302.
FCM Upstream
Messages being silently dropped by FCM backend.
Batch Send API
Requests being rejected with error code UNIMPLEMENTED and the error message "The API is deprecated."
GCM SDKs - Register Tokens
Requests being rejected with HTTP code 301.
GCM SDKs - Send Messages
Requests being rejected with error code 400 and the error message "V3 token has been deprecated."
JS SDKs version < 7.0.0
Requests being rejected with HTTP code 501.
Using server key to access Instance ID and device group management APIs
Requests being rejected with HTTP code 401.
What's the difference between OAuth 2.0 tokens and server keys?
An OAuth 2.0 token is a short-lived token derived from a service account . It's Google's standard auth model and it's more secure than static server keys.
Note that the request headers differ when you use OAuth 2.0 tokens for requests to different endpoints.
HTTP v1 API : Authorization: Bearer $oauth_token
Instance ID server API and Device group management API : Authorization: Bearer $oauth_token access_token_auth: true
Can I migrate my requests to the new API all at once?
We recommend that you slowly ramp up your traffic to the new API. If you expect to send more than 600,000 messages/min on a regular basis, contact Firebase support for instructions on how to increase quota or get recommendations on how to spread out traffic.
What's the difference between the HTTP v1 API and the legacy APIs when I send messages to topics/device groups?
Topics: you don't need to add the "/topics/" prefix to your topic target when you use the v1 API.
Device groups: You can use a group token as a token target in the HTTP v1 API. However, the HTTP v1 API doesn't return the success/failure counts in the response. We recommend that you use FCM topics or manage your device groups by yourself.
Does the HTTP v1 API support sending messages to multiple tokens in one request?
No. This feature, called "multicast" in legacy HTTP APIs, is not supported by the HTTP v1 API, which is better designed for scalability.
For use cases where end-to-end latency is critical, or where total fanout size is small (fewer than 1 million), Google recommends sending multiple separate requests using the HTTP v1 API. The HTTP v1 API over HTTP/2 performs similarly for 99.9% of multicast requests (sending < 100 tokens). For outlier use cases (sending 1000 tokens), it achieves up to a third of the throughput rate, so additional concurrency is needed to optimize for this atypical use case. Users can experience more reliability and availability with the HTTP v1 API than with legacy multicast.
For use cases where throughput and egress bandwidth are prioritized or where total fanout size is large (greater than 1 million), Google recommends topic messaging. While topic messaging requires a one-time action to subscribe recipients to a topic, it offers up to a 10,000 QPS per project fanout rate without a maximum limit on topic size.
What versions of the Firebase Admin SDK have the new APIs?
پلت فرم
Firebase Admin SDK version
Node.js
>=11.7.0
پایتون
>=6.2.0
جاوا
>=9.2.0
برو
>=4.12.0
دات نت
>=2.4.0
What's the difference between the batch send API and the HTTP v1 API?
The FCM batch send API uses the same message format and authentication mechanism as the HTTP v1 API. However, it uses a different endpoint. If you want to improve efficiency, you should consider using HTTP/2 to send multiple requests over the same HTTP connection to the HTTP v1 API.
What should I do if I can't access my project?
Please reach out to the Google Cloud support team for help.
Can new projects enable the legacy Cloud Messaging API?
No. Starting from 5/20/2024, new projects will no longer be allowed to enable our legacy APIs.
FCM quotas and limits
I need to notify a large customer base within 2 minutes.
Unfortunately, this use case cannot be supported. You must spread your traffic out over 5 minutes.
My app notifies users of events. The messages must be delivered immediately to support my business model. Can I get more quota?
Unfortunately, we cannot grant quota increases for this reason. You must spread your traffic out over 5 minutes.
My messages are about scheduled events and I need to send all my traffic at the top of the hour.
We recommend that you start sending the notifications at least 5 minutes prior to the event.
How long will it take for my quota request to be fulfilled?
This depends a bit on your use of FCM. In any case, you can expect an answer in a few business days. In some cases, there may be some back-and-forth regarding your usage of FCM and various circumstances, which can prolong the process. If all requirements are met, most requests will be handled within 2 weeks.
429s are hard for me / my business to deal with. Can I get an exemption or more quota to avoid getting 429s?
While we understand that quota limits can be challenging, quotas are vital to keeping the service reliable and we can't grant exemptions.
Can I get more quota for a temporary event?
You may request additional quota to support an event lasting up to 1 month. File the request at least 1 month in advance of the event and with clear details on when the event starts and ends, and FCM will make every practical effort to fulfill the request (no increase can be guaranteed). These quota increases will be reverted after the event's end date.
Is my current quota subject to change?
While Google will not do so lightly, quotas may be changed as needed to protect the integrity of the system. When possible, Google will notify you in advance of such changes.
Cloud Storage for Firebase
Cloud Storage for Firebase : Why can't I use Cloud Storage for Firebase ?
Cloud Storage for Firebase creates a default bucket in the App Engine no-cost tier. This allows you to quickly get up and running with Firebase and Cloud Storage for Firebase , without having to put in a credit card or enable a Cloud Billing account. It also allows you to easily share data between Firebase and a Google Cloud project.
There are, however, two known cases where this bucket cannot be created and you will be unable to use Cloud Storage for Firebase :
A project imported from Google Cloud which had a App Engine Master/Slave Datastore application.
A project imported from Google Cloud which has domain prefixed projects. For example: domain.com:project-1234 .
There are currently no workarounds to these issues, and we recommend that you create a new project in the Firebase console and enable Cloud Storage for Firebase in that project.
Cloud Storage for Firebase : Why do I get error code 412 responses about service account permissions and failed service account operations when using the Cloud Storage for Firebase API?
It's likely you're getting 412 error codes either because the Cloud Storage for Firebase API is not enabled for your project or a necessary service account is missing the required permissions.
Cloud Storage for Firebase : On Spark plan projects, can I store executable files?
For no-cost (Spark) plan projects, Firebase blocks uploads and hosting of certain executable file types for Windows, Android and Apple by Cloud Storage for Firebase and Firebase Hosting . این سیاست برای جلوگیری از سوء استفاده در پلتفرم ما وجود دارد.
Serving, hosting and file uploads of disallowed files are blocked for all Spark projects created on or after Sept 28th, 2023. For existing Spark projects with files uploaded before that date, such files can still be uploaded and hosted.
This restriction applies to Spark plan projects. Projects on the pay as you go (Blaze) plan are not affected.
The following file types cannot be hosted on Firebase Hosting and Cloud Storage for Firebase :
Windows files with .exe , .dll and .bat extensions
Android files with .apk extension
Apple platform files with .ipa extension
چه کاری باید انجام دهم؟
If you still want to host these file types after September 28th, 2023:
For Hosting: upgrade to the Blaze plan before you can deploy these file types to Firebase Hosting via the firebase deploy command.
For Storage: upgrade to the Blaze plan to upload these file types to the bucket of your choice using the GCS CLI, the Firebase console, or Google Cloud console.
Use Firebase tools to manage your Firebase Hosting and Cloud Storage resources.
For managing resources in Firebase Hosting , use the Firebase console to delete releases according to this guide .
For managing resources in Cloud Storage , navigate to the Storage product page in your project.
On the Files tab, locate disallowed files to delete in your folder hierarchy, then select them using the checkbox next to the filename(s) on the left-hand side of the panel.
Click Delete , and confirm the files were deleted.
Cloud Storage for Firebase : Why do I see an unexpected increase in upload and download operations?
Previously, download and upload requests to the Cloud Storage for Firebase API were not being counted properly. We have taken steps to fix this issue, starting from September 15, 2023.
For Blaze users, upload and download operations will start counting towards your monthly bill. For Spark users, they will start counting towards your monthly free limit.
We recommend monitoring your Usage page for any increases that may count towards your limits.
Cloud Storage for Firebase : Why do I see new service account IDs associated with 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 service account that Cloud Storage for Firebase uses 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 . As of September 19, 2022, this service account is no longer supported.
You can view all service accounts associated with your project in the Firebase console, on the Service accounts tab .
Adding the new service account
If you removed the service account previously or the service account is not present in your project, you may do one of the following to add the account.
(Recommended) Automated: Use the AddFirebase REST endpoint to re-import your bucket into Firebase. You will only need to call this endpoint once, not once for each linked bucket.
We strongly discourage you from 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 in Disabling a service account .
Dynamic Links : Why does my Android app access each Dynamic Link twice?
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 to false in each of the deep link activities to clear it for the case when the activity is triggered outside the main activity.
Firebase Local Emulator Suite
Why do Emulator Suite logs show an error starting with "Multiple projectIds are not recommended in single project mode"?
This message means the 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 the firebase.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:
The default project set at the command line. By default, the project ID will be taken on startup from the project selected with firebase init or firebase use . To view the list of projects (and see which one is selected) use firebase projects:list .
تست های واحد The project ID is often specified in calls to the Rules Unit Testing library methods initializeTestEnvironment or initializeTestApp . Other testing code may initialize with initializeApp(config) .
The command line --project flag. Passing the Firebase CLI --project flag overrides the default project. You'll need to ensure the value of the flag matches the project ID in unit tests and app initialization.
Platform-specific places to check:
وب
The projectId property in your JavaScript firebaseConfig object, used in initializeApp .
اندروید
The project_id property inside the google-services.json configuration file.
Apple platforms
The PROJECT_ID property in the GoogleService-Info.plist configuration file.
To disable single project mode, update firebase.json with the singleProjectMode key:
Hosting : On Spark plan projects, can I store executable files?
For no-cost (Spark) plan projects, Firebase blocks uploads and hosting of certain executable file types for Windows, Android and Apple by Cloud Storage for Firebase and Firebase Hosting . این سیاست برای جلوگیری از سوء استفاده در پلتفرم ما وجود دارد.
Serving, hosting and file uploads of disallowed files are blocked for all Spark projects created on or after Sept 28th, 2023. For existing Spark projects with files uploaded before that date, such files can still be uploaded and hosted.
This restriction applies to Spark plan projects. Projects on the pay as you go (Blaze) plan are not affected.
The following file types cannot be hosted on Firebase Hosting and Cloud Storage for Firebase :
Windows files with .exe , .dll and .bat extensions
Android files with .apk extension
Apple platform files with .ipa extension
چه کاری باید انجام دهم؟
If you still want to host these file types after September 28th, 2023:
For Hosting: upgrade to the Blaze plan before you can deploy these file types to Firebase Hosting via the firebase deploy command.
For Storage: upgrade to the Blaze plan to upload these file types to the bucket of your choice using the GCS CLI, the Firebase console, or Google Cloud console.
Use Firebase tools to manage your Firebase Hosting and Cloud Storage resources.
For managing resources in Firebase Hosting , use the Firebase console to delete releases according to this guide .
For managing resources in Cloud Storage , navigate to the Storage product page in your project.
On the Files tab, locate disallowed files to delete in your folder hierarchy, then select them using the checkbox next to the filename(s) on the left-hand side of the panel.
Click Delete , and confirm the files were deleted.
Hosting : Why does my Hosting release history table in the Firebase console show file counts that are more than what my local project actually has?
Firebase automatically adds extra files containing metadata about the Hosting site, and these files are included in the total file count for the release.
Hosting : What's the largest file size that I can deploy to Firebase Hosting ?
Hosting has a maximum size limit of 2 GB for individual files.
We recommend storing larger files using Cloud Storage , which offers a maximum size limit in the terabyte range for individual objects.
Hosting : How many Hosting sites can I have per Firebase project?
Performance Monitoring : How many custom URL patterns can I create?
You can create up to 400 total custom URL patterns per app and up to 100 custom URL patterns per domain for that app.
Performance Monitoring : Why am I not seeing real time display of performance data?
To view real time performance data, make sure that your app uses a Performance Monitoring SDK version that's compatible with real time data processing.
iOS — v7.3.0 or later
tvOS — v8.9.0 or later
Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
Realtime Database
Realtime Database : Why was my Realtime Database reported bandwidth lower than average between September 2016 and March 2017?
For our bandwidth calculations, we normally include SSL encryption overhead (based on layer 5 of the OSI model). However, in September 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.
Realtime Database : What are the scaling limitations of the Realtime 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.
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 the Firebase console that you've exceeded your Realtime Database usage limits, you can address it based on the usage limit you've exceeded. To see your Realtime Database usage, go to the Realtime DatabaseUsage dashboard in the Firebase console.
If you're over your download limit, you can upgrade your Firebase 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:
Add queries to limit the data that your listen operations return.
Check for unindexed queries.
Use listeners that only download updates to data — for example, on() instead of once() .
Use security rules to block unauthorized downloads.
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:
Run periodic cleanup jobs.
Reduce any duplicate data in your database.
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.
Remote Config
Remote Config : Why don't fetched values change the behavior and appearance of my app?
Unless you fetch values with fetchAndActivate() , values are stored locally but not activated. To activate fetched values so that they can take effect, call activate . This design lets you control when the behavior and appearance of your app changes, because you can choose when to call activate . After you call activate , your app source code determines when updated parameter values are used.
For example, you could fetch values and then activate them the next time a user starts your app, which removes the need to delay app startup while your app waits for fetched values from the service. Changes to your app's behavior and appearance then occur when your app uses the updated parameter values.
Remote Config : I am making a lot of fetch requests while developing my app. Why doesn't my app always get the latest values from the service when it sends fetch requests?
During app development, you might want to fetch and activate configs very frequently (many times per hour) to let you rapidly iterate as you develop and test your app. To accommodate rapid iteration on a project with up to 10 developers, you can temporarily set a FirebaseRemoteConfigSettings object with a low minimum fetch interval ( setMinimumFetchIntervalInSeconds ) in your app.
Remote Config : How quickly does the Remote Config service return fetched values after my app sends a fetch request?
Devices usually receive fetched values in less than a second, and often receive fetched values in milliseconds. The Remote Config service handles fetch requests within milliseconds, but the time required to complete a fetch request will depend on the network speed of the device and the latency of the network connection used by the device.
If your goal is to make fetched values take effect in your app as soon as possible, but without creating a jarring user experience, consider adding calls to fetchAndActivate each time that your app does a full screen refresh.
Firebase User Segmentation Storage stores Firebase 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.
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 the product-specific Firebase SDKs to your app, like Analytics , 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:
Understand Firebase projects — provides brief overviews of several important concepts about Firebase projects, including their relationship with Google Cloud and the basic hierarchy of a project and its apps and resources.
General best practices for setting up Firebase projects — provides general, high-level best practices for setting up Firebase projects and registering your apps with a project so that you have a clear development workflow that uses distinct environments.
Note that for all Firebase projects, Firebase automatically adds a label of firebase:enabled within the Labels page for your project in the Google Cloud console. Learn more about this label in our FAQ .
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 to Creating and Managing Organizations .
How do I add Firebase to an existing Google Cloud project?
You can add Firebase to these existing projects using any of the following options:
Using the Firebase console: In the Firebase console landing page, click Add Project , and then select your existing project from the Project name menu.
Using a programmatic option:
Call the Firebase Management REST API endpoint addFirebase .
Why does my Google Cloud project have a label of firebase:enabled ?
In the Labels page for your project in the Google Cloud console, you may see a label of firebase:enabled (specifically, a Key of firebase 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 the relationship 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 the REST API projects.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 your Google Cloud project. To do that, you need to add Firebase via the Firebase console (or, for advanced use cases, via the Firebase Management REST API or the Firebase 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:
In a list of projects that you're viewing within the Firebase console
In the response from running the Firebase CLI command firebase projects:list
Try these troubleshooting steps:
First, try accessing your project by visiting the project's URL directly. از فرمت زیر استفاده کنید: https://console.firebase.google.com/project/ PROJECT-ID /overview
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.
Make sure that your project has the label firebase:enabled in the Labels page for your project in the Google Cloud console. Firebase and Google Cloud use this label to list your Firebase projects. If you do not see this label but the Firebase Management API is enabled for your project, then manually add the label (specifically, a Key of firebase with a Value of enabled ).
Make sure that you're assigned one of the basic IAM roles (Owner, Editor, Viewer) or a role that has Firebase-related permissions in it, for example a Firebase predefined role . You can view your role(s) in the IAM 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 the Firebase 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, contact Firebase Support .
در هر حساب چند پروژه می توانم داشته باشم؟
Spark pricing plan — Your project quota is limited to a small number of projects (usually around 5-10).
طرح قیمت گذاری Blaze - تا زمانی که حساب Cloud Billing شما وضعیت خوبی داشته باشد، سهمیه پروژه شما به ازای هر حساب Cloud Billing به میزان قابل توجهی افزایش می یابد.
Note that the complete deletion of a project requires 30 days and counts toward your quota until it is fully deleted.
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 for Google 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 our general 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 the Google Cloud console to make your request and have it evaluated. Learn more about quota 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 settingsProject settings > General , then in the Your project card under Environment , click edit to change the environment type.
Where can I find the App ID for my Firebase app?
In the Firebase console, go to your settingsProject 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 .
Either of the following Firebase roles: Owner or Firebase Admin و
Either of the following Google Play access levels: account Owner or Admin
For linking your AdMob app , you need to be both a Firebase project owner and an AdMob administrator.
For linking your AdWords account , you need to be both a Firebase project owner and an AdWords administrator.
For linking your BigQuery project , you need to be the Firebase project owner.
What open source notices should I include in my app?
On Apple platforms, the Firebase pod contains a NOTICES file which includes the relevant entries. The Firebase Android SDK contains a helper Activity for showing license information.
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 permission resourcemanager.projects.setIamPolicy ).
Here are the places where you can assign and manage roles:
The Google Cloud console offers an expansive set of tools to assign roles to project members in the IAM page . In the Cloud console, you can also create and manage custom roles , as well as give service accounts access to your project.
Note that in the Google Cloud console, project members are called principals .
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 can contact 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 your Google 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 you have access to the project in the Firebase console, you can view the list of project members, including Owners, in the Users and permissions page of the Firebase console.
اگر در کنسول Firebase به پروژه دسترسی ندارید ، بررسی کنید که آیا به پروژه در کنسول Google Cloud دسترسی دارید یا خیر. You can view the list of project members, including Owners, in the IAM page of the Google Cloud console.
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 can contact 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 managing Google Analytics properties), the administrator may need to assign themselves the actual 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 an Owner . A project's Owner is the person who can perform several important administrative actions (like assigning roles and managing Google Analytics properties), and Firebase Support can only fulfill administrative requests from demonstrated project Owners.
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 the actual 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 the Firebase 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 the actual Owner role to open the project and perform the required actions. Learn more about why and when to assign the Owner role .
Platforms and frameworks
Visit the platform-specific troubleshooting & FAQ pages for helpful tips and answers for more FAQ.
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 currently 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:
The Firebase console returns an error page that says your project may not exist or that you don't have access to the project.
The Firebase console doesn't display your project even when you enter its project ID or project name in the console's search field.
Try these troubleshooting steps:
First, try accessing your project by visiting the project's URL directly. از فرمت زیر استفاده کنید: https://console.firebase.google.com/project/ PROJECT-ID /overview
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 you're assigned one of the basic IAM roles (Owner, Editor, Viewer) or a role that has Firebase-related permissions in it, for example a Firebase predefined role . You can view your role(s) in the IAM 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 the Firebase 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, contact Firebase Support .
Why is the Firebase console not loading for me?
This FAQ is applicable if you're experiencing any of the following issues:
A page in the Firebase console never finishes loading.
Data within a page doesn't load as expected.
You receive browser error messages when loading the Firebase console.
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 .
A project Owner can add other members to the project, set up integrations (project linking to services like BigQuery or Slack), and has full edit access for the project.
A project Editor has full edit access for the project.
A project Viewer has only read access for the project. Note that the Firebase console currently does not hide/disable edit UI controls from project Viewers, but these operations will fail for project members assigned the Viewer role.
Firebase also supports:
Firebase predefined roles — Curated Firebase-specific roles that enable more granular access control than the basic roles of Owner, Editor, and Viewer.
Custom roles — Fully customized IAM roles that you create to tailor a set of permissions that meet the specific requirements of your organization.
قیمت گذاری
Which products are paid? Which are no-cost?
Firebase's paid infrastructure products are the Realtime Database , Cloud Storage for Firebase , Cloud Functions , Hosting , Test Lab , and phone authentication. We offer a no-cost tier for all of these features.
Firebase also has many no-cost products: Analytics , Cloud Messaging , the Notifications composer, Remote Config , App Indexing , Dynamic Links , and Crash Reporting . Use of these products is subject only to the product's traffic control policies (eg quotas, fair access and other service protections) in all plans, including our no-cost Spark plan. In addition, all Authentication features beyond phone authentication are no-cost.
Does Firebase offer no-cost trial credits for paid products?
Firebase paid services can be used under the Google 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 evaluate Google Cloud and Firebase products and services.
During the Google Cloud Free Trial period, you'll be provided a Free Trial Cloud Billing account. Any Firebase project that uses that billing account will be on the Blaze pricing plan during the free trial period.
Don't worry, setting up this Free Trial Cloud Billing account does not enable us to charge you. You are not charged unless you explicitly enable billing by upgrading your Free Trial Cloud Billing account to a paid account. میتوانید در طول دوره آزمایشی، در هر زمانی به یک حساب پولی ارتقا دهید. After you've upgraded, you can still use any remaining credits (within the 90-day period).
Once the free trial expires, you'll need to either downgrade your project to the Spark pricing plan or set up the Blaze pricing plan in the Firebase console to continue using your Firebase project.
Our Spark plan is a great place to develop your app at no cost. You get all the no-cost Firebase features ( Analytics , the Notifications composer, Crashlytics , and so on) and generous amounts of our paid infrastructure features. However, if you exceed your Spark 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 plan.
Blaze pricing plan
Our Blaze plan is designed for production apps. The Blaze plan also allows you to extend your app with paid Google Cloud features. You pay only for the resources that you consume, allowing you to scale with demand. We strive to make our Blaze plan prices competitive with industry-leading cloud providers.
What happened to the free SMS on the Spark plan?
Starting September 2024, to improve the security and service quality of Phone Authentication, Firebase projects must be linked to a Cloud Billing account to enable and use the SMS Service.
How can I monitor my usage and billing?
You can track your usage of project resources in the Firebase console on any of the following dashboards:
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 Spark pricing plan. بر این اساس،
Existing Spark and Blaze plan projects and any new projects can no longer switch to or sign up for the Flame plan.
If you moved an existing Flame plan project to a different pricing plan, the project cannot return to the Flame plan.
Projects downgraded to the Spark plan can be upgraded to the Blaze plan to resume additional paid services.
References to the Flame plan have been removed from documentation.
Do you have more questions about the Flame plan retirement? Read some of the additional FAQs below.
Want to learn about the other pricing plans offered by Firebase? Visit our Firebase pricing page ! If you'd like to start moving any existing projects to another pricing plan, you can do that in the Firebase 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. چه کار کنم؟
Sign up for the Blaze pricing plan, and make sure to set 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. چطوری دوباره عوضش کنم؟
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 consider setting up budget alerts for your project.
My project was automatically switched to a different pricing plan as part of the Flame plan retirement. چه کار کنم؟
If your project requires additional quota beyond what is provided with the Spark 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.
How is the no-cost usage in the Blaze plan different from the no-cost usage in the Spark plan?
No-cost usage on the Blaze plan is calculated daily. Usage limits also differ from the Spark plan for Cloud Functions , phone authentication, and Test Lab .
For Cloud Functions , no-cost usage on the Blaze plan is calculated at the Cloud Billing account level, not the project level and has the following limits:
2M invocations/month
400K GB-seconds/month
200K CPU-seconds/month
5 GB of networking egress/month
For phone authentication, no-cost usage on the Blaze plan is calculated monthly.
For Test Lab , no-cost usage on the Blaze plan has the following limits:
30 physical device minutes/day
60 virtual device minutes/day
Does the no-cost usage quota reset when I change from a Spark to a Blaze plan?
No-cost usage from the Spark plan is included in the Blaze plan. No-cost usage does not reset when moving to a Blaze plan.
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 plan limit is 100 and cannot be raised. The Flame and Blaze plans have 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, please read Scale with Multiple Databases .
What happens if I exceed Spark plan storage or download limits for Realtime Database ?
To provide you with a predictable price, the resources available to you in the Spark plans are capped. 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.
What happens if I exceed Spark plan simultaneous connection limits for Realtime Database ?
When your app reaches its concurrency limit on the Spark 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.
How does Firebase's integration with Google Cloud work?
Firebase is deeply integrated with Google 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. به طور مشخص:
Certain Firebase products are backed directly by Google Cloud , such as Cloud Storage for Firebase . The list of products backed by Google Cloud will continue to grow over time.
Many of your settings, including collaborators and billing information, are shared by Firebase and Google Cloud . Your usage of both Firebase and Google Cloud appears on the same bill.
In addition, when you upgrade to the Blaze plan, you can use any of Google Cloud 's world-class Infrastructure-as-a-Service and APIs directly inside your Firebase project, at standard Google Cloud pricing . You can also export data from Google Cloud directly to BigQuery for analysis. To learn more, see Link 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 the Google Cloud site for more details.
What happens to my Firebase project if I add or remove billing accounts for that project in the Google Cloud console?
If a Cloud Billing account is added to a project in the Google Cloud console, the same project will automatically be upgraded to the Firebase Blaze plan if that project is currently on the Spark plan.
In contrast, if an existing active Cloud Billing account is removed from a project in the Google Cloud console, that project will be downgraded to the Firebase Spark plan.
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.
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.
Can I cap usage on the Blaze plan?
No, you cannot currently cap your Blaze plan usage. We are evaluating options for supporting caps on Blaze plan usage.
Blaze users can define a budget for their project or account, and receive alerts as their spending approaches those limits. Learn how to set up budget alerts .
What are automated backups? Do you offer hourly backups?
Automated backups are an advanced feature for customers on our Blaze pricing plan that backs up your Firebase Realtime Database data once a day and uploads it to Google Cloud Storage .
We do not offer hourly backups.
Do you offer open-source, nonprofit, or educational discounts?
Our Spark 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?
Our Blaze plan is suitable for enterprises of all sizes, and our SLA meets or exceeds the industry standard for cloud infrastructure. However, we do not currently offer enterprise contracts, pricing, or support, nor do we offer dedicated infrastructure hosting (that is, on-premises installations) for services like our Realtime Database . We are hard at work 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 in the Blaze plan, where you pay only for the features 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 , and Ads billing is managed from the Ads console.
Cloud Functions pricing
Why do I need a billing account to use Cloud Functions for Firebase ?
Cloud Functions for Firebase relies on some paid Google services. New function deployments with Firebase CLI 11.2.0 and higher rely on Cloud Build and Artifact Registry . Deployments to older versions use Cloud Build in the same way, but rely on Container Registry and Cloud Storage for storage instead of Artifact Registry . Usage of these services will be billed in addition to existing pricing.
Storage space for Firebase CLI 11.2.0 and newer versions
Artifact Registry provides the containers in which functions run. Artifact Registry provides the first 500MB at no cost, so your first function deployments may not incur any fees. Above that threshold, each additional GB of storage is billed at $0.10 per month.
Storage space for Firebase CLI 11.1.x and prior versions
For functions deployed to older versions, Container Registry , provides the containers in which functions run. You'll be billed for each container required to deploy a function. You may notice small charges for each container stored—for example, 1GB of storage is billed at $0.026 per month .
To understand more about how your bill might change, please review the following
Does Cloud Functions for Firebase still have no-cost usage?
بله. On the Blaze plan, Cloud Functions provides a no-cost tier for invocations, compute time, and internet traffic. The first 2,000,000 invocations, 400,000 GB-sec, 200,000 CPU-sec, and 5 GB of Internet egress traffic is provided at no cost each month. You'll be charged only for usage above those thresholds.
After the first 500MB of no-cost storage, each deployment operation will incur small-scale charges for the storage space used for the function's container. If your development process depends on deploying functions for testing, you can further minimize costs by using the Firebase Local Emulator Suite during development.
Is Firebase planning to raise the quotas and limits for Cloud Functions for Firebase ?
No. There are no plans to change the quotas except for the removal of a maximum build time limit; instead of receiving errors or warnings when the daily build quota of 120 minutes is reached, you'll be billed under the terms of the Blaze pricing plan. See Quotas and limits .
Can I get the Google Cloud $300 credit?
Yes, you can create a Cloud Billing account in the Google Cloud console to get the $300 credit, then link that Cloud Billing account to a Firebase project.
Note that if you do this, you have to then set up the Blaze pricing plan in the Firebase console in order for your project to continue working after the $300 credit is exhausted.
I want to follow a codelab to learn about Firebase. Can you give me a temporary billing account?
نه متاسفم You can use the Firebase emulator for development without having a Cloud Billing account. Alternatively, try applying for a Google Cloud free trial . If you're still having trouble paying your bill because of this change, contact Firebase Support.
I'm worried I'm going to rack up a huge bill.
You can set up budget alerts in the Google Cloud console to help control costs. Also, you can set limits on the number of billed instances created for each of your functions. To get an idea of costing for typical scenarios, see the Cloud Functions Pricing examples.
To use extensions, you will need to upgrade to the Blaze pricing plan. You will be charged a small amount (typically around $0.01 per month for the Firebase resources required by each extension you install (even if they are not used), in addition to any charges associated with your use of Firebase services.
Cloud Storage for Firebase pricing
How do I predict how much I will be billed for upload and download operations?
Visit the Firebase Pricing page and use the Blaze 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.
What happens if I exceed Spark plan upload, download or storage limits for Cloud Storage for Firebase ?
When you exceed limits for Cloud Storage in a project on the Spark plan, the result depends on the type of limit that you exceed:
If you exceed the GB stored limit, you will not be able to store any more data in that project unless you remove some of the data stored or upgrade to a plan that provides more storage space, or unlimited storage space.
If you exceed the GB downloaded limit, your app will not be able to download more data until the next day (starting at midnight, US Pacific Time), unless you upgrade to a plan with less restrictive limits, or with no limits.
If you exceed the upload or download operations limit, your app will not be able to upload or download more data until the next day (starting at midnight, US Pacific Time), unless you upgrade to a plan with less restrictive limits, or with no محدودیت ها
حریم خصوصی
Where can I find information about privacy and security in Firebase?
Do the Firebase SDKs log any usage/diagnostic information outside of Analytics?
بله. This is currently 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, on GitHub
A/B Testing
A/B Testing : How many experiments can I create and run?
You are allowed up to 300 experiments per project, which could consist of up to 24 running experiments, with the rest as draft or completed.
A/B Testing : Why can't I view my experiments after unlinking and re-linking my project to Google Analytics?
Linking to a different Google Analytics property will cause you to lose access to experiments created beforehand. To regain access to a previous experiment, re-link your project to the Google Analytics property that was linked when the experiment was created.
A/B Testing : Why do I receive a "Project not linked to Google Analytics" message when creating a Remote Config experiment?
If you've already linked Firebase and Google Analytics , but still see a message that Google Analytics is not linked, make sure that an Analytics stream exists for all apps in your project. Currently, all apps in a project must be connected to a Google Analytics stream to use A/B Testing.
You can find the list of all active streams on the Google Analytics integration details page within the Firebase console, accessed from settingsProject Settingschevron_rightIntegrationschevron_rightGoogle Analyticschevron_rightManage .
Creating a Google Analytics stream for any app that does not have one should resolve the issue. There are a few ways to create streams for missing apps:
If you only have one or two apps missing an associated Google Analytics stream, you can choose one of the following methods to add a Google Analytics stream:
Delete and re-add any app without an active stream in the Firebase console.
From the Google Analytics console , select Admin , click Data Streams , then click Add stream , add the missing app's details, and click Register app .
If you have more than a few missing app streams, unlinking and relinking your Google Analytics property is the fastest and most efficient way to create the missing app streams:
From settingsProject Settings , select Integrations .
Within the Google Analytics card, click Manage to access Firebase and Google Analytics settings.
Make a note of the Google Analytics Property ID and the Linked Google Analytics account .
Click more_vertMore and select Unlink Analytics from this project .
Review the warning that appears (don't worry here; you will relink the same property in the next step), then click Unlink Google Analytics .
When unlinking is complete, you'll be redirected to the Integrations page.
Within the Google Analytics card, click Enable to begin the relinking process.
Select your Analytics account from the Select account list.
Next to Automatically create a new property in this account , click editEdit and, from the Analytics property list that appears, select your property ID.
A list of all apps in your project appears. Existing stream mappings for each app are listed, and apps that do not have a stream will have one created for them.
Click Enable Google Analytics to relink the property.
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.
For Android projects : Add the dependency for the Google Mobile Ads SDK to your build.gradle file: implementation 'com.google.android.gms:play-services-ads:23.3.0'
Analytics : Why is Google Analytics a recommended part of using Firebase products?
Google Analytics is a free and unlimited analytics solution that works with Firebase features to deliver powerful insights. It enables you to view event logs in Crashlytics , notification effectiveness in FCM , deep link performance for Dynamic Links , and in-app purchase data from Google Play . It powers advanced audience targeting in Remote Config , Remote Config personalization, and more.
Google Analytics acts as a layer of intelligence in the Firebase console to provide you with more actionable insights about how to develop a high quality app, grow your user base, and earn more money.
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 your Google Analytics data is shared in your project settings anytime. Learn more about Data 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:
تنظیمات اشتراک داده
Data retention settings
Time zone and currency settings
To update your property settings, follow these steps:
In the Firebase console, go to your settings > Project settings .
Go to the Integrations tab, and then in the Google Analytics card, click Manage or View link .
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 the Analytics data will not 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 the Firebase 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 about linking a Google Analytics property to your Firebase project.
Analytics : If my Analytics property was deleted, can I link a new Google Analytics property to my Firebase project and start using Analytics again?
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 about linking 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:
Crashlytics — You can no longer see crash-free users, breadcrumb logs, and/or velocity alerts.
Cloud Messaging and In-App Messaging — You can no longer use targeting, campaign metrics, audience segmentation, and analytics labels.
Remote Config — You can no longer use targeted configurations or Personalization.
A/B Testing — You can no longer use A/B Testing since the experiment measurement is supplied by Google Analytics.
Dynamic Links — Any feature that relies on data from Google Analytics will be disrupted.
In addition, the following integrations will be affected:
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 an audience 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
Firebase 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.
منطقه
کد
پس از میلاد
آندورا
AE
امارات متحده عربی
AF
افغانستان
AG
آنتیگوا و باربودا
AL
آلبانی
AM
ارمنستان
AO
آنگولا
AR
آرژانتین
AS
ساموآی آمریکایی
AT
اتریش
AU
استرالیا
AW
آروبا
AZ
آذربایجان
BA
بوسنی و هرزگوین
BB
باربادوس
BD
بنگلادش
BE
بلژیک
BF
بورکینافاسو
BG
بلغارستان
بی جی
بنین
BM
برمودا
BN
برونئی دارالسلام
BO
بولیوی
BR
برزیل
BS
باهاما
BT
بوتان
BW
بوتسوانا
توسط
بلاروس
BZ
بلیز
CA
کانادا
سی دی
کنگو، (کینشاسا)
CF
جمهوری آفریقای مرکزی
CG
کنگو (برازاویل)
CH
سوئیس
CI
ساحل عاج
CK
جزایر کوک
CL
شیلی
سی ام
کامرون
CO
کلمبیا
CR
کاستاریکا
CV
کیپ ورد
CW
کوراسائو
CY
قبرس
CZ
جمهوری چک
DE
آلمان
دی جی
جیبوتی
DK
دانمارک
DM
دومینیکا
انجام دهید
جمهوری دومینیکن
DZ
الجزایر
EC
اکوادور
EG
مصر
ES
اسپانیا
ET
اتیوپی
FI
فنلاند
اف جی
فیجی
FK
جزایر فالکلند (مالویناس)
FM
میکرونزی، ایالات فدرال
FO
جزایر فارو
FR
فرانسه
GA
گابن
گیگابایت
انگلستان
جی دی
گرانادا
جنرال الکتریک
گرجستان
GF
گویان فرانسه
جی جی
گرنزی
GH
غنا
GI
جبل الطارق
GL
گرینلند
جنرال موتورز
گامبیا
GP
گوادلوپ
GQ
گینه استوایی
GR
یونان
GT
گواتمالا
GY
گویان
HK
هنگ کنگ، SAR چین
HN
هندوراس
منابع انسانی
کرواسی
HT
هائیتی
HU
مجارستان
شناسه
اندونزی
IE
ایرلند
IL
اسرائیل
IM
جزیره من
در
هند
IQ
عراق
IT
ایتالیا
JE
جرسی
JM
جامائیکا
JO
اردن
JP
ژاپن
KE
کنیا
KG
قرقیزستان
KH
کامبوج
KM
کومور
KN
سنت کیتس و نویس
KR
کره (جنوبی)
KW
کویت
KY
جزایر کیمن
KZ
قزاقستان
لس آنجلس
لائوس PDR
LB
لبنان
LC
سنت لوسیا
LI
لیختن اشتاین
LK
سریلانکا
LS
لسوتو
آن
لیتوانی
LU
لوکزامبورگ
LV
لتونی
LY
لیبی
MA
مراکش
MD
مولداوی
من
مونته نگرو
MF
سن مارتین (بخش فرانسوی)
ام جی
ماداگاسکار
MK
مقدونیه، جمهوری
MM
میانمار
MN
مغولستان
MO
ماکائو، SAR چین
اماس
مونتسرات
MT
مالت
MU
موریس
مگاوات
مالاوی
MX
مکزیک
من
مالزی
MZ
موزامبیک
NA
نامیبیا
NC
کالدونیای جدید
NE
نیجر
NF
جزیره نورفولک
NG
نیجریه
NI
نیکاراگوئه
NL
هلند
نه
نروژ
NP
نپال
NZ
نیوزلند
OM
عمان
PA
پاناما
PE
پرو
PG
پاپوآ گینه نو
PH
فیلیپین
PK
پاکستان
PL
لهستان
PM
سنت پیر و میکلون
روابط عمومی
پورتوریکو
PS
سرزمین فلسطین
PT
پرتغال
PY
پاراگوئه
QA
قطر
RE
رئونیون
RO
رومانی
RS
صربستان
RU
فدراسیون روسیه
RW
رواندا
SA
عربستان سعودی
SC
سیشل
SE
سوئد
SG
سنگاپور
SH
سنت هلنا
SI
اسلوونی
SK
اسلواکی
SL
سیرالئون
SN
سنگال
SR
سورینام
ST
سائوتومه و پرنسیپ
SV
السالوادور
SZ
سوازیلند
TC
جزایر تورکس و کایکوس
TG
توگو
TH
تایلند
TL
تیمور شرقی
TM
ترکمنستان
به
تونگا
TR
ترکیه
TT
ترینیداد و توباگو
TW
تایوان، جمهوری چین
TZ
تانزانیا، جمهوری متحده
UA
اوکراین
UG
اوگاندا
ایالات متحده
ایالات متحده آمریکا
UY
اروگوئه
UZ
ازبکستان
VC
سنت وینسنت و گرنادین
VE
ونزوئلا (جمهوری بولیوار)
VG
جزایر ویرجین بریتانیا
VI
جزایر ویرجین، ایالات متحده
VN
ویتنام
WS
ساموآ
بله
یمن
YT
مایوت
ZA
آفریقای جنوبی
ZM
زامبیا
ZW
زیمبابوه
Firebase 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:
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 below 50% imply many sent SMS but few successful logins, which is a common indicator of bad actors and SMS traffic pumping.
Use SMS Region Policy to either deny SMS regions with low success rates, or only allow certain regions if your app is only intended for distribution in certain markets.
Limit your authorized authentication domains
Use the Authentication settings dashboard to manage authorized domains. The localhost domain is added by default to the approved authentication domains to simplify development. Consider removing localhost from the authorized domains in your production project to prevent bad actors from running code on theirlocalhost 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.
Remember that you need to enforce App Check for Authentication in the Firebase console (consider monitoring traffic before enforcing). Also, double check your reCAPTCHA Enterprise approved 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).
Firebase 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.
Firebase 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)
Make sure that Google sign-in is properly enabled as an authentication provider:
Within the Sign in method tab, disable and then re-enable the Google sign-in method (even if it's already enabled):
Open the Google sign-in method, disable it, and then click Save .
Re-open the Google sign-in method, enable it, and then click Save .
Also, in the Google sign-in provider configuration of the Authentication section, make sure that the OAuth client ID and secret match the web client displayed in the Credentials page of the Google Cloud console (look in the OAuth 2.0 Client IDs section).
Firebase 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 the list of authorized domains for 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:
If you use Hosting -provided Auth helpers to log users in with the Authentication JS SDK, then Firebase automatically obtains your API key with the rest of your Firebase configuration each time you deploy to Firebase Hosting . Make sure that the authDomain in your web app firebaseConfig is properly configured to use one of the domains for that Hosting site. You can verify this by going to https:// authDomain __/firebase/init.json , and checking that the projectId matches that from your firebaseConfig .
If you self-host the sign-in code , then you can use a __/firebase/init.json file to provide the Firebase configuration to the self-hosted Authentication JS SDK Redirect helper. The API key and the projectId listed in this config file should match your web app firebaseConfig .
Check to make sure this API key hasn't been deleted: Go to the APIs & Services > Credentials panel in the Google Cloud console where all the API keys for your project are listed.
If the Browser key has not been deleted, check the following:
If you self-host the sign-in code, make sure the API key listed in your __/firebase/init.json file matches the API key in the Cloud console. Correct the key in the file, if necessary, then redeploy your app.
If the Browser key has been deleted, you can have Firebase generate a new API key for you: In the Firebase console, go to settings > Project settings , then in the Your apps section, click on your web app. This action automatically creates an API key that you can see in the SDK setup and configuration section for your web app.
Note that in the Cloud console this new API key will not be called Browser key ; instead, it will be the same name as your Firebase Web App's nickname. If you decide to add API restrictions to this new API key, make sure the Firebase Authentication API is in the list of allowed APIs.
Once your new API key is created, complete the applicable steps below:
If you use reserved Hosting URLs , then redeploy your app to Firebase so that it can automatically obtain the new API key with the rest of your Firebase configuration.
If you self-host the sign-in code , copy the new API key and add it to your __/firebase/init.json file, then redeploy your app.
Firebase Authentication : How do I manually construct an OAuth web client??
Open the Credentials page of the Google Cloud console.
At the top of the page, select Create credentials > OAuth client ID .
If you're prompted to configure your consent screen, follow the on-screen instructions, and then continue with the following steps of this FAQ.
Create the OAuth web client:
For the Application Type , select Web application .
For the Authorized JavaScript Origins , add the following:
http://localhost
http://localhost:5000
https:// PROJECT_ID .firebaseapp.com
https:// PROJECT_ID .web.app
For the Authorized Redirect URIs , add the following:
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. روی ذخیره کلیک کنید.
Firebase 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:
If the OAuth brand name is available, then the %APP_NAME% in the email template will be the OAuth brand name (same as pre-December 2022 behavior).
If the OAuth brand name is not available, here's how the %APP_NAME% in the email template is determined:
For web apps , the %APP_NAME% will be the default Firebase Hosting site name (the value preceding .firebaseapp.com and .web.app and usually the Firebase project ID).
For mobile apps:
If the Android package name or iOS bundle ID is present in the request, then the %APP_NAME% will be the app name used in the Play Store or App Store (respectively).
Otherwise, the %APP_NAME% will be the default Firebase Hosting site name (the value preceding .firebaseapp.com and .web.app and usually the Firebase project ID).
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
Cloud Functions runtime support
How do I upgrade to the latest supported version of Node.js?
How can I make sure I deployed my functions to a specific Node.js runtime?
In the Firebase console, go to the functions dashboard , select a function, and check the function's language under Additional details .
I use Firebase Extensions. Will I be affected by Cloud Functions runtime updates?
بله. Since extensions use Cloud Functions , the runtime of your extensions will need to be updated on the same timeline as Cloud Functions.
We recommend that you periodically update to the latest version of each extension installed in your project. You can upgrade your projects' extensions via the Firebase console or Firebase CLI .
Cloud Messaging
Cloud Messaging : What's the difference between the Notifications composer and Cloud Messaging ?
Firebase Cloud Messaging provides a complete set of messaging capabilities through its client SDKs and HTTP and XMPP server protocols. For deployments with more complex messaging requirements, FCM is the right choice.
The Notifications composer is a lightweight, serverless messaging solution built on Firebase Cloud Messaging . With a user-friendly graphical console and reduced coding requirements, the Notifications composer lets users easily send messages to reengage and retain users, foster app growth, and support marketing campaigns.
قابلیت ها
Notifications composer
Cloud Messaging
هدف
Single device
Clients subscribed to topics (ie weather)
Clients in predefined user segment (app, version, language)
Clients in specified analytics audiences
Clients in device groups
Upstream from client to server
نوع پیام
Notifications up to 2kb
Data messages up to 4kb
تحویل
فوری
Future client device local time
تجزیه و تحلیل
Built-in Notifications analytics collection and funnel analytics
Cloud Messaging : Apple announced they're deprecating the legacy binary protocol for APNs. آیا لازم است کاری انجام دهم؟
No. Firebase Cloud Messaging switched to the HTTP/2-based APNs protocol in 2017. If you are using FCM to send notifications to iOS devices, there should be no action required on your part.
Cloud Messaging : Do I need to use other Firebase services in order to use FCM ?
You can use Firebase Cloud Messaging as a standalone component, in the same manner as you did with GCM, without using other Firebase services.
Cloud Messaging : I am an existing Google Cloud Messaging (GCM) developer. Should I move to Firebase Cloud Messaging ?
FCM is the new version of GCM under the Firebase brand. It inherits GCM's core infrastructure, with new SDKs to make Cloud Messaging development easier.
Benefits of upgrading to FCM SDK include:
Simpler client development. You no longer have to write your own registration or subscription retry logic.
An out-of-the-box notification solution. You can use the Notifications composer, a serverless notifications solution with a web console that lets anyone send notifications to target specific audiences based on insights from Google Analytics.
To upgrade from GCM SDKs to FCM SDKs, see the guides for migrating Android and iOS apps.
Cloud Messaging : Why do my targeted devices apparently fail to receive messages?
When it looks like devices haven't successfully received messages, check first for these two potential causes:
Foreground message handling for notification messages . Client apps need to add message handling logic to handle notification messages when the app is in the foreground on the device. See the details for iOS and Android .
Network firewall restrictions . If your organization has a firewall that restricts the traffic to or from the Internet, you need to configure it to allow connectivity with FCM in order for your Firebase Cloud Messaging client apps to receive messages. The ports to open are:
5228
5229
5230
FCM usually uses 5228, but it sometimes uses 5229 and 5230. FCM does not provide specific IPs, so you should allow your firewall to accept outgoing connections to all IP addresses contained in the IP blocks listed in Google's ASN of 15169 .
Cloud Messaging : I have implemented onMessageReceived in my Android app, but it is not being called.
When your app is in the background, notification messages are displayed in the system tray, and onMessageReceived is not called. For notification messages with a data payload, the notification message is displayed in the system tray, and the data that was included with the notification message can be retrieved from the intent launched when the user taps on the notification.
Notifications composer: What's the difference between the Notifications composer and Cloud Messaging ?
The Notifications composer is a lightweight, serverless messaging solution built on Firebase Cloud Messaging . With a user-friendly graphical console and reduced coding requirements, the Notifications composer lets users easily send messages to reengage and retain users, foster app growth, and support marketing campaigns.
Firebase Cloud Messaging provides a complete set of messaging capabilities through its client SDKs and HTTP and XMPP server protocols. For deployments with more complex messaging requirements, FCM is the right choice.
Here's a comparison of the messaging capabilities provided by Firebase Cloud Messaging and the Notifications composer:
قابلیت ها
Notifications composer
Cloud Messaging
هدف
Single device
Clients subscribed to topics (ie weather)
Clients in predefined user segment (app, version, language)
Clients in specified analytics audiences
Clients in device groups
Upstream from client to server
نوع پیام
Notifications up to 2kb
Data messages up to 4kb
تحویل
فوری
Future client device local time
تجزیه و تحلیل
Built-in Notifications analytics collection and funnel analytics
Notifications composer: I am an existing Google Cloud Messaging (GCM) developer, and I want to use the Notifications composer. چه کار کنم؟
The Notifications composer is an out-of-the-box solution that lets anyone send notifications to target specific audiences based on insights from Google Analytics. Also, the Notifications composer provides funnel analysis for every message, allowing easy evaluation of notification effectiveness.
If you are an existing GCM developer, to use the Notifications composer you have to upgrade from GCM SDKs to FCM SDKs. See the guides for migrating Android and iOS apps.
FCM features deprecated in June 2023
Which FCM APIs were deprecated on June 20, 2023, and what should I do if I am using those APIs?
The following APIs/SDKs will be affected by the deprecation:
Server APIs
نام API
نقطه پایانی API
Impact on users
اقدام لازم است
Legacy HTTP protocol
https://fcm.googleapis.com/fcm/send
Requests to the endpoint will start failing after 6/21/2024.
API calls to FirebaseMessaging.send in the app won't trigger upstream messages to the app server after 6/21/2024.
Implement this functionality in your server logic. For example, some developers implement their own HTTP/gRPC endpoint and call the endpoint directly to send messages from their clients to the app server. See this gRPC Quick start for an example implementation of upstream messaging using gRPC.
Batch Send API
https://fcm.googleapis.com/batch
Requests to the endpoint will start failing after 6/21/2024.
These APIs will stop working after 6/21/2024 because they call the batch send API .
Upgrade to the latest Firebase Admin SDK and use the new APIs instead: sendEach()/ sendEachAsync()/send_each()/sendEachForMulticast()/sendEachForMulticastAsync()/ send_each_for_multicast() .
Note that the new APIs no longer call the deprecated batch send API, and for this reason they may create more concurrent HTTP connections than the old APIs.
Client SDKs
SDK versions
Impact on users
اقدام لازم است
GCM SDKs (deprecated in 2018)
Apps using GCM SDKs will not be able to register tokens nor receive messages from FCM after 6/21/2024.
Upgrade your Android SDK to the latest Firebase SDK if you haven't already done so.
JS SDKs version <7.0.0 (breaking change at version 7.0.0 in 2019)
Web apps using older JS SDKs will not be able to register tokens after 6/21/2024.
Upgrade your Firebase Web SDK to the latest version.
Will I see a service downgrade before June 2024?
No. You have 12 months (06/20/2023 - 06/21/2024) to migrate from the old APIs to new APIs without any service downgrade. We strongly recommend you to plan the migration as early as possible so you won't be impacted by the decommissioning of the APIs in June 2024.
After June 2024, you may see increased errors or lack of functionality when using the APIs/SDKs listed above (see the next FAQ for more information).
How and when will the deprecated APIs be shut down?
FCM will start a gradual shutdown of deprecated APIs around July 22nd, 2024. After this date, deprecated services will be subject to a "flickering" process in which increasing numbers of requests will return error responses. During the gradual ramp-down period you can expect the following behavior and error responses to increase in frequency over time:
دسته بندی
انتظار چه چیزی
Legacy HTTP protocol
Requests being rejected with HTTP code 301.
Legacy XMPP protocol
Requests being rejected with error code 302.
FCM Upstream
Messages being silently dropped by FCM backend.
Batch Send API
Requests being rejected with error code UNIMPLEMENTED and the error message "The API is deprecated."
GCM SDKs - Register Tokens
Requests being rejected with HTTP code 301.
GCM SDKs - Send Messages
Requests being rejected with error code 400 and the error message "V3 token has been deprecated."
JS SDKs version < 7.0.0
Requests being rejected with HTTP code 501.
Using server key to access Instance ID and device group management APIs
Requests being rejected with HTTP code 401.
What's the difference between OAuth 2.0 tokens and server keys?
An OAuth 2.0 token is a short-lived token derived from a service account . It's Google's standard auth model and it's more secure than static server keys.
Note that the request headers differ when you use OAuth 2.0 tokens for requests to different endpoints.
HTTP v1 API : Authorization: Bearer $oauth_token
Instance ID server API and Device group management API : Authorization: Bearer $oauth_token access_token_auth: true
Can I migrate my requests to the new API all at once?
We recommend that you slowly ramp up your traffic to the new API. If you expect to send more than 600,000 messages/min on a regular basis, contact Firebase support for instructions on how to increase quota or get recommendations on how to spread out traffic.
What's the difference between the HTTP v1 API and the legacy APIs when I send messages to topics/device groups?
Topics: you don't need to add the "/topics/" prefix to your topic target when you use the v1 API.
Device groups: You can use a group token as a token target in the HTTP v1 API. However, the HTTP v1 API doesn't return the success/failure counts in the response. We recommend that you use FCM topics or manage your device groups by yourself.
Does the HTTP v1 API support sending messages to multiple tokens in one request?
No. This feature, called "multicast" in legacy HTTP APIs, is not supported by the HTTP v1 API, which is better designed for scalability.
For use cases where end-to-end latency is critical, or where total fanout size is small (fewer than 1 million), Google recommends sending multiple separate requests using the HTTP v1 API. The HTTP v1 API over HTTP/2 performs similarly for 99.9% of multicast requests (sending < 100 tokens). For outlier use cases (sending 1000 tokens), it achieves up to a third of the throughput rate, so additional concurrency is needed to optimize for this atypical use case. Users can experience more reliability and availability with the HTTP v1 API than with legacy multicast.
For use cases where throughput and egress bandwidth are prioritized or where total fanout size is large (greater than 1 million), Google recommends topic messaging. While topic messaging requires a one-time action to subscribe recipients to a topic, it offers up to a 10,000 QPS per project fanout rate without a maximum limit on topic size.
What versions of the Firebase Admin SDK have the new APIs?
پلت فرم
Firebase Admin SDK version
Node.js
>=11.7.0
پایتون
>=6.2.0
جاوا
>=9.2.0
برو
>=4.12.0
دات نت
>=2.4.0
What's the difference between the batch send API and the HTTP v1 API?
The FCM batch send API uses the same message format and authentication mechanism as the HTTP v1 API. However, it uses a different endpoint. If you want to improve efficiency, you should consider using HTTP/2 to send multiple requests over the same HTTP connection to the HTTP v1 API.
What should I do if I can't access my project?
Please reach out to the Google Cloud support team for help.
Can new projects enable the legacy Cloud Messaging API?
No. Starting from 5/20/2024, new projects will no longer be allowed to enable our legacy APIs.
FCM quotas and limits
I need to notify a large customer base within 2 minutes.
Unfortunately, this use case cannot be supported. You must spread your traffic out over 5 minutes.
My app notifies users of events. The messages must be delivered immediately to support my business model. Can I get more quota?
Unfortunately, we cannot grant quota increases for this reason. You must spread your traffic out over 5 minutes.
My messages are about scheduled events and I need to send all my traffic at the top of the hour.
We recommend that you start sending the notifications at least 5 minutes prior to the event.
How long will it take for my quota request to be fulfilled?
This depends a bit on your use of FCM. In any case, you can expect an answer in a few business days. In some cases, there may be some back-and-forth regarding your usage of FCM and various circumstances, which can prolong the process. If all requirements are met, most requests will be handled within 2 weeks.
429s are hard for me / my business to deal with. Can I get an exemption or more quota to avoid getting 429s?
While we understand that quota limits can be challenging, quotas are vital to keeping the service reliable and we can't grant exemptions.
Can I get more quota for a temporary event?
You may request additional quota to support an event lasting up to 1 month. File the request at least 1 month in advance of the event and with clear details on when the event starts and ends, and FCM will make every practical effort to fulfill the request (no increase can be guaranteed). These quota increases will be reverted after the event's end date.
Is my current quota subject to change?
While Google will not do so lightly, quotas may be changed as needed to protect the integrity of the system. When possible, Google will notify you in advance of such changes.
Cloud Storage for Firebase
Cloud Storage for Firebase : Why can't I use Cloud Storage for Firebase ?
Cloud Storage for Firebase creates a default bucket in the App Engine no-cost tier. This allows you to quickly get up and running with Firebase and Cloud Storage for Firebase , without having to put in a credit card or enable a Cloud Billing account. It also allows you to easily share data between Firebase and a Google Cloud project.
There are, however, two known cases where this bucket cannot be created and you will be unable to use Cloud Storage for Firebase :
A project imported from Google Cloud which had a App Engine Master/Slave Datastore application.
A project imported from Google Cloud which has domain prefixed projects. For example: domain.com:project-1234 .
There are currently no workarounds to these issues, and we recommend that you create a new project in the Firebase console and enable Cloud Storage for Firebase in that project.
Cloud Storage for Firebase : Why do I get error code 412 responses about service account permissions and failed service account operations when using the Cloud Storage for Firebase API?
It's likely you're getting 412 error codes either because the Cloud Storage for Firebase API is not enabled for your project or a necessary service account is missing the required permissions.
Cloud Storage for Firebase : On Spark plan projects, can I store executable files?
For no-cost (Spark) plan projects, Firebase blocks uploads and hosting of certain executable file types for Windows, Android and Apple by Cloud Storage for Firebase and Firebase Hosting . این سیاست برای جلوگیری از سوء استفاده در پلتفرم ما وجود دارد.
Serving, hosting and file uploads of disallowed files are blocked for all Spark projects created on or after Sept 28th, 2023. For existing Spark projects with files uploaded before that date, such files can still be uploaded and hosted.
This restriction applies to Spark plan projects. Projects on the pay as you go (Blaze) plan are not affected.
The following file types cannot be hosted on Firebase Hosting and Cloud Storage for Firebase :
Windows files with .exe , .dll and .bat extensions
Android files with .apk extension
Apple platform files with .ipa extension
چه کاری باید انجام دهم؟
If you still want to host these file types after September 28th, 2023:
For Hosting: upgrade to the Blaze plan before you can deploy these file types to Firebase Hosting via the firebase deploy command.
For Storage: upgrade to the Blaze plan to upload these file types to the bucket of your choice using the GCS CLI, the Firebase console, or Google Cloud console.
Use Firebase tools to manage your Firebase Hosting and Cloud Storage resources.
For managing resources in Firebase Hosting , use the Firebase console to delete releases according to this guide .
For managing resources in Cloud Storage , navigate to the Storage product page in your project.
On the Files tab, locate disallowed files to delete in your folder hierarchy, then select them using the checkbox next to the filename(s) on the left-hand side of the panel.
Click Delete , and confirm the files were deleted.
Cloud Storage for Firebase : Why do I see an unexpected increase in upload and download operations?
Previously, download and upload requests to the Cloud Storage for Firebase API were not being counted properly. We have taken steps to fix this issue, starting from September 15, 2023.
For Blaze users, upload and download operations will start counting towards your monthly bill. For Spark users, they will start counting towards your monthly free limit.
We recommend monitoring your Usage page for any increases that may count towards your limits.
Cloud Storage for Firebase : Why do I see new service account IDs associated with 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 service account that Cloud Storage for Firebase uses 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 . As of September 19, 2022, this service account is no longer supported.
You can view all service accounts associated with your project in the Firebase console, on the Service accounts tab .
Adding the new service account
If you removed the service account previously or the service account is not present in your project, you may do one of the following to add the account.
(Recommended) Automated: Use the AddFirebase REST endpoint to re-import your bucket into Firebase. You will only need to call this endpoint once, not once for each linked bucket.
We strongly discourage you from 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 in Disabling a service account .
Dynamic Links : Why does my Android app access each Dynamic Link twice?
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 to false in each of the deep link activities to clear it for the case when the activity is triggered outside the main activity.
Firebase Local Emulator Suite
Why do Emulator Suite logs show an error starting with "Multiple projectIds are not recommended in single project mode"?
This message means the 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 the firebase.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:
The default project set at the command line. By default, the project ID will be taken on startup from the project selected with firebase init or firebase use . To view the list of projects (and see which one is selected) use firebase projects:list .
تست های واحد The project ID is often specified in calls to the Rules Unit Testing library methods initializeTestEnvironment or initializeTestApp . Other testing code may initialize with initializeApp(config) .
The command line --project flag. Passing the Firebase CLI --project flag overrides the default project. You'll need to ensure the value of the flag matches the project ID in unit tests and app initialization.
Platform-specific places to check:
وب
The projectId property in your JavaScript firebaseConfig object, used in initializeApp .
اندروید
The project_id property inside the google-services.json configuration file.
Apple platforms
The PROJECT_ID property in the GoogleService-Info.plist configuration file.
To disable single project mode, update firebase.json with the singleProjectMode key:
Hosting : On Spark plan projects, can I store executable files?
For no-cost (Spark) plan projects, Firebase blocks uploads and hosting of certain executable file types for Windows, Android and Apple by Cloud Storage for Firebase and Firebase Hosting . این سیاست برای جلوگیری از سوء استفاده در پلتفرم ما وجود دارد.
Serving, hosting and file uploads of disallowed files are blocked for all Spark projects created on or after Sept 28th, 2023. For existing Spark projects with files uploaded before that date, such files can still be uploaded and hosted.
This restriction applies to Spark plan projects. Projects on the pay as you go (Blaze) plan are not affected.
The following file types cannot be hosted on Firebase Hosting and Cloud Storage for Firebase :
Windows files with .exe , .dll and .bat extensions
Android files with .apk extension
Apple platform files with .ipa extension
چه کاری باید انجام دهم؟
If you still want to host these file types after September 28th, 2023:
For Hosting: upgrade to the Blaze plan before you can deploy these file types to Firebase Hosting via the firebase deploy command.
For Storage: upgrade to the Blaze plan to upload these file types to the bucket of your choice using the GCS CLI, the Firebase console, or Google Cloud console.
Use Firebase tools to manage your Firebase Hosting and Cloud Storage resources.
For managing resources in Firebase Hosting , use the Firebase console to delete releases according to this guide .
For managing resources in Cloud Storage , navigate to the Storage product page in your project.
On the Files tab, locate disallowed files to delete in your folder hierarchy, then select them using the checkbox next to the filename(s) on the left-hand side of the panel.
Click Delete , and confirm the files were deleted.
Hosting : Why does my Hosting release history table in the Firebase console show file counts that are more than what my local project actually has?
Firebase automatically adds extra files containing metadata about the Hosting site, and these files are included in the total file count for the release.
Hosting : What's the largest file size that I can deploy to Firebase Hosting ?
Hosting has a maximum size limit of 2 GB for individual files.
We recommend storing larger files using Cloud Storage , which offers a maximum size limit in the terabyte range for individual objects.
Hosting : How many Hosting sites can I have per Firebase project?
Performance Monitoring : How many custom URL patterns can I create?
You can create up to 400 total custom URL patterns per app and up to 100 custom URL patterns per domain for that app.
Performance Monitoring : Why am I not seeing real time display of performance data?
To view real time performance data, make sure that your app uses a Performance Monitoring SDK version that's compatible with real time data processing.
iOS — v7.3.0 or later
tvOS — v8.9.0 or later
Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
Realtime Database
Realtime Database : Why was my Realtime Database reported bandwidth lower than average between September 2016 and March 2017?
For our bandwidth calculations, we normally include SSL encryption overhead (based on layer 5 of the OSI model). However, in September 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.
Realtime Database : What are the scaling limitations of the Realtime 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.
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 the Firebase console that you've exceeded your Realtime Database usage limits, you can address it based on the usage limit you've exceeded. To see your Realtime Database usage, go to the Realtime DatabaseUsage dashboard in the Firebase console.
If you're over your download limit, you can upgrade your Firebase 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:
Add queries to limit the data that your listen operations return.
Check for unindexed queries.
Use listeners that only download updates to data — for example, on() instead of once() .
Use security rules to block unauthorized downloads.
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:
Run periodic cleanup jobs.
Reduce any duplicate data in your database.
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.
Remote Config
Remote Config : Why don't fetched values change the behavior and appearance of my app?
Unless you fetch values with fetchAndActivate() , values are stored locally but not activated. To activate fetched values so that they can take effect, call activate . This design lets you control when the behavior and appearance of your app changes, because you can choose when to call activate . After you call activate , your app source code determines when updated parameter values are used.
For example, you could fetch values and then activate them the next time a user starts your app, which removes the need to delay app startup while your app waits for fetched values from the service. Changes to your app's behavior and appearance then occur when your app uses the updated parameter values.
Remote Config : I am making a lot of fetch requests while developing my app. Why doesn't my app always get the latest values from the service when it sends fetch requests?
During app development, you might want to fetch and activate configs very frequently (many times per hour) to let you rapidly iterate as you develop and test your app. To accommodate rapid iteration on a project with up to 10 developers, you can temporarily set a FirebaseRemoteConfigSettings object with a low minimum fetch interval ( setMinimumFetchIntervalInSeconds ) in your app.
Remote Config : How quickly does the Remote Config service return fetched values after my app sends a fetch request?
Devices usually receive fetched values in less than a second, and often receive fetched values in milliseconds. The Remote Config service handles fetch requests within milliseconds, but the time required to complete a fetch request will depend on the network speed of the device and the latency of the network connection used by the device.
If your goal is to make fetched values take effect in your app as soon as possible, but without creating a jarring user experience, consider adding calls to fetchAndActivate each time that your app does a full screen refresh.
Firebase User Segmentation Storage stores Firebase 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.
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 the product-specific Firebase SDKs to your app, like Analytics , 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:
Understand Firebase projects — provides brief overviews of several important concepts about Firebase projects, including their relationship with Google Cloud and the basic hierarchy of a project and its apps and resources.
General best practices for setting up Firebase projects — provides general, high-level best practices for setting up Firebase projects and registering your apps with a project so that you have a clear development workflow that uses distinct environments.
Note that for all Firebase projects, Firebase automatically adds a label of firebase:enabled within the Labels page for your project in the Google Cloud console. Learn more about this label in our FAQ .
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 to Creating and Managing Organizations .
How do I add Firebase to an existing Google Cloud project?
You can add Firebase to these existing projects using any of the following options:
Using the Firebase console: In the Firebase console landing page, click Add Project , and then select your existing project from the Project name menu.
Using a programmatic option:
Call the Firebase Management REST API endpoint addFirebase .
Why does my Google Cloud project have a label of firebase:enabled ?
In the Labels page for your project in the Google Cloud console, you may see a label of firebase:enabled (specifically, a Key of firebase 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 the relationship 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 the REST API projects.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 your Google Cloud project. To do that, you need to add Firebase via the Firebase console (or, for advanced use cases, via the Firebase Management REST API or the Firebase 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:
In a list of projects that you're viewing within the Firebase console
In the response from running the Firebase CLI command firebase projects:list
Try these troubleshooting steps:
First, try accessing your project by visiting the project's URL directly. از فرمت زیر استفاده کنید: https://console.firebase.google.com/project/ PROJECT-ID /overview
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.
Make sure that your project has the label firebase:enabled in the Labels page for your project in the Google Cloud console. Firebase and Google Cloud use this label to list your Firebase projects. If you do not see this label but the Firebase Management API is enabled for your project, then manually add the label (specifically, a Key of firebase with a Value of enabled ).
Make sure that you're assigned one of the basic IAM roles (Owner, Editor, Viewer) or a role that has Firebase-related permissions in it, for example a Firebase predefined role . You can view your role(s) in the IAM 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 the Firebase 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, contact Firebase Support .
در هر حساب چند پروژه می توانم داشته باشم؟
Spark pricing plan — Your project quota is limited to a small number of projects (usually around 5-10).
طرح قیمت گذاری Blaze - تا زمانی که حساب Cloud Billing شما وضعیت خوبی داشته باشد، سهمیه پروژه شما به ازای هر حساب Cloud Billing به میزان قابل توجهی افزایش می یابد.
Note that the complete deletion of a project requires 30 days and counts toward your quota until it is fully deleted.
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 for Google 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 our general 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 the Google Cloud console to make your request and have it evaluated. Learn more about quota 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 settingsProject settings > General , then in the Your project card under Environment , click edit to change the environment type.
Where can I find the App ID for my Firebase app?
In the Firebase console, go to your settingsProject 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 .
Either of the following Firebase roles: Owner or Firebase Admin و
Either of the following Google Play access levels: account Owner or Admin
For linking your AdMob app , you need to be both a Firebase project owner and an AdMob administrator.
For linking your AdWords account , you need to be both a Firebase project owner and an AdWords administrator.
For linking your BigQuery project , you need to be the Firebase project owner.
What open source notices should I include in my app?
On Apple platforms, the Firebase pod contains a NOTICES file which includes the relevant entries. The Firebase Android SDK contains a helper Activity for showing license information.
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 permission resourcemanager.projects.setIamPolicy ).
Here are the places where you can assign and manage roles:
The Google Cloud console offers an expansive set of tools to assign roles to project members in the IAM page . In the Cloud console, you can also create and manage custom roles , as well as give service accounts access to your project.
Note that in the Google Cloud console, project members are called principals .
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 can contact 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 your Google 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 you have access to the project in the Firebase console, you can view the list of project members, including Owners, in the Users and permissions page of the Firebase console.
اگر در کنسول Firebase به پروژه دسترسی ندارید ، بررسی کنید که آیا به پروژه در کنسول Google Cloud دسترسی دارید یا خیر. You can view the list of project members, including Owners, in the IAM page of the Google Cloud console.
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 can contact 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 managing Google Analytics properties), the administrator may need to assign themselves the actual 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 an Owner . A project's Owner is the person who can perform several important administrative actions (like assigning roles and managing Google Analytics properties), and Firebase Support can only fulfill administrative requests from demonstrated project Owners.
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 the actual 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 the Firebase 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 the actual Owner role to open the project and perform the required actions. Learn more about why and when to assign the Owner role .
Platforms and frameworks
Visit the platform-specific troubleshooting & FAQ pages for helpful tips and answers for more FAQ.
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 currently 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:
The Firebase console returns an error page that says your project may not exist or that you don't have access to the project.
The Firebase console doesn't display your project even when you enter its project ID or project name in the console's search field.
Try these troubleshooting steps:
First, try accessing your project by visiting the project's URL directly. از فرمت زیر استفاده کنید: https://console.firebase.google.com/project/ PROJECT-ID /overview
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 you're assigned one of the basic IAM roles (Owner, Editor, Viewer) or a role that has Firebase-related permissions in it, for example a Firebase predefined role . You can view your role(s) in the IAM 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 the Firebase 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, contact Firebase Support .
Why is the Firebase console not loading for me?
This FAQ is applicable if you're experiencing any of the following issues:
A page in the Firebase console never finishes loading.
Data within a page doesn't load as expected.
You receive browser error messages when loading the Firebase console.
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 .
A project Owner can add other members to the project, set up integrations (project linking to services like BigQuery or Slack), and has full edit access for the project.
A project Editor has full edit access for the project.
A project Viewer has only read access for the project. Note that the Firebase console currently does not hide/disable edit UI controls from project Viewers, but these operations will fail for project members assigned the Viewer role.
Firebase also supports:
Firebase predefined roles — Curated Firebase-specific roles that enable more granular access control than the basic roles of Owner, Editor, and Viewer.
Custom roles — Fully customized IAM roles that you create to tailor a set of permissions that meet the specific requirements of your organization.
قیمت گذاری
Which products are paid? Which are no-cost?
Firebase's paid infrastructure products are the Realtime Database , Cloud Storage for Firebase , Cloud Functions , Hosting , Test Lab , and phone authentication. We offer a no-cost tier for all of these features.
Firebase also has many no-cost products: Analytics , Cloud Messaging , the Notifications composer, Remote Config , App Indexing , Dynamic Links , and Crash Reporting . Use of these products is subject only to the product's traffic control policies (eg quotas, fair access and other service protections) in all plans, including our no-cost Spark plan. In addition, all Authentication features beyond phone authentication are no-cost.
Does Firebase offer no-cost trial credits for paid products?
Firebase paid services can be used under the Google 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 evaluate Google Cloud and Firebase products and services.
During the Google Cloud Free Trial period, you'll be provided a Free Trial Cloud Billing account. Any Firebase project that uses that billing account will be on the Blaze pricing plan during the free trial period.
Don't worry, setting up this Free Trial Cloud Billing account does not enable us to charge you. You are not charged unless you explicitly enable billing by upgrading your Free Trial Cloud Billing account to a paid account. میتوانید در طول دوره آزمایشی، در هر زمانی به یک حساب پولی ارتقا دهید. After you've upgraded, you can still use any remaining credits (within the 90-day period).
Once the free trial expires, you'll need to either downgrade your project to the Spark pricing plan or set up the Blaze pricing plan in the Firebase console to continue using your Firebase project.
Our Spark plan is a great place to develop your app at no cost. You get all the no-cost Firebase features ( Analytics , the Notifications composer, Crashlytics , and so on) and generous amounts of our paid infrastructure features. However, if you exceed your Spark 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 plan.
Blaze pricing plan
Our Blaze plan is designed for production apps. The Blaze plan also allows you to extend your app with paid Google Cloud features. You pay only for the resources that you consume, allowing you to scale with demand. We strive to make our Blaze plan prices competitive with industry-leading cloud providers.
What happened to the free SMS on the Spark plan?
Starting September 2024, to improve the security and service quality of Phone Authentication, Firebase projects must be linked to a Cloud Billing account to enable and use the SMS Service.
How can I monitor my usage and billing?
You can track your usage of project resources in the Firebase console on any of the following dashboards:
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 Spark pricing plan. بر این اساس،
Existing Spark and Blaze plan projects and any new projects can no longer switch to or sign up for the Flame plan.
If you moved an existing Flame plan project to a different pricing plan, the project cannot return to the Flame plan.
Projects downgraded to the Spark plan can be upgraded to the Blaze plan to resume additional paid services.
References to the Flame plan have been removed from documentation.
Do you have more questions about the Flame plan retirement? Read some of the additional FAQs below.
Want to learn about the other pricing plans offered by Firebase? Visit our Firebase pricing page ! If you'd like to start moving any existing projects to another pricing plan, you can do that in the Firebase 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. چه کار کنم؟
Sign up for the Blaze pricing plan, and make sure to set 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. چطوری دوباره عوضش کنم؟
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 consider setting up budget alerts for your project.
My project was automatically switched to a different pricing plan as part of the Flame plan retirement. چه کار کنم؟
If your project requires additional quota beyond what is provided with the Spark 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.
How is the no-cost usage in the Blaze plan different from the no-cost usage in the Spark plan?
No-cost usage on the Blaze plan is calculated daily. Usage limits also differ from the Spark plan for Cloud Functions , phone authentication, and Test Lab .
For Cloud Functions , no-cost usage on the Blaze plan is calculated at the Cloud Billing account level, not the project level and has the following limits:
2M invocations/month
400K GB-seconds/month
200K CPU-seconds/month
5 GB of networking egress/month
For phone authentication, no-cost usage on the Blaze plan is calculated monthly.
For Test Lab , no-cost usage on the Blaze plan has the following limits:
30 physical device minutes/day
60 virtual device minutes/day
Does the no-cost usage quota reset when I change from a Spark to a Blaze plan?
No-cost usage from the Spark plan is included in the Blaze plan. No-cost usage does not reset when moving to a Blaze plan.
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 plan limit is 100 and cannot be raised. The Flame and Blaze plans have 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, please read Scale with Multiple Databases .
What happens if I exceed Spark plan storage or download limits for Realtime Database ?
To provide you with a predictable price, the resources available to you in the Spark plans are capped. 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.
What happens if I exceed Spark plan simultaneous connection limits for Realtime Database ?
When your app reaches its concurrency limit on the Spark 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.
How does Firebase's integration with Google Cloud work?
Firebase is deeply integrated with Google 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. به طور مشخص:
Certain Firebase products are backed directly by Google Cloud , such as Cloud Storage for Firebase . The list of products backed by Google Cloud will continue to grow over time.
Many of your settings, including collaborators and billing information, are shared by Firebase and Google Cloud . Your usage of both Firebase and Google Cloud appears on the same bill.
In addition, when you upgrade to the Blaze plan, you can use any of Google Cloud 's world-class Infrastructure-as-a-Service and APIs directly inside your Firebase project, at standard Google Cloud pricing . You can also export data from Google Cloud directly to BigQuery for analysis. To learn more, see Link 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 the Google Cloud site for more details.
What happens to my Firebase project if I add or remove billing accounts for that project in the Google Cloud console?
If a Cloud Billing account is added to a project in the Google Cloud console, the same project will automatically be upgraded to the Firebase Blaze plan if that project is currently on the Spark plan.
In contrast, if an existing active Cloud Billing account is removed from a project in the Google Cloud console, that project will be downgraded to the Firebase Spark plan.
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.
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.
Can I cap usage on the Blaze plan?
No, you cannot currently cap your Blaze plan usage. We are evaluating options for supporting caps on Blaze plan usage.
Blaze users can define a budget for their project or account, and receive alerts as their spending approaches those limits. Learn how to set up budget alerts .
What are automated backups? Do you offer hourly backups?
Automated backups are an advanced feature for customers on our Blaze pricing plan that backs up your Firebase Realtime Database data once a day and uploads it to Google Cloud Storage .
We do not offer hourly backups.
Do you offer open-source, nonprofit, or educational discounts?
Our Spark 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?
Our Blaze plan is suitable for enterprises of all sizes, and our SLA meets or exceeds the industry standard for cloud infrastructure. However, we do not currently offer enterprise contracts, pricing, or support, nor do we offer dedicated infrastructure hosting (that is, on-premises installations) for services like our Realtime Database . We are hard at work 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 in the Blaze plan, where you pay only for the features 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 , and Ads billing is managed from the Ads console.
Cloud Functions pricing
Why do I need a billing account to use Cloud Functions for Firebase ?
Cloud Functions for Firebase relies on some paid Google services. New function deployments with Firebase CLI 11.2.0 and higher rely on Cloud Build and Artifact Registry . Deployments to older versions use Cloud Build in the same way, but rely on Container Registry and Cloud Storage for storage instead of Artifact Registry . Usage of these services will be billed in addition to existing pricing.
Storage space for Firebase CLI 11.2.0 and newer versions
Artifact Registry provides the containers in which functions run. Artifact Registry provides the first 500MB at no cost, so your first function deployments may not incur any fees. Above that threshold, each additional GB of storage is billed at $0.10 per month.
Storage space for Firebase CLI 11.1.x and prior versions
For functions deployed to older versions, Container Registry , provides the containers in which functions run. You'll be billed for each container required to deploy a function. You may notice small charges for each container stored—for example, 1GB of storage is billed at $0.026 per month .
To understand more about how your bill might change, please review the following
Does Cloud Functions for Firebase still have no-cost usage?
بله. On the Blaze plan, Cloud Functions provides a no-cost tier for invocations, compute time, and internet traffic. The first 2,000,000 invocations, 400,000 GB-sec, 200,000 CPU-sec, and 5 GB of Internet egress traffic is provided at no cost each month. You'll be charged only for usage above those thresholds.
After the first 500MB of no-cost storage, each deployment operation will incur small-scale charges for the storage space used for the function's container. If your development process depends on deploying functions for testing, you can further minimize costs by using the Firebase Local Emulator Suite during development.
Is Firebase planning to raise the quotas and limits for Cloud Functions for Firebase ?
No. There are no plans to change the quotas except for the removal of a maximum build time limit; instead of receiving errors or warnings when the daily build quota of 120 minutes is reached, you'll be billed under the terms of the Blaze pricing plan. See Quotas and limits .
Can I get the Google Cloud $300 credit?
Yes, you can create a Cloud Billing account in the Google Cloud console to get the $300 credit, then link that Cloud Billing account to a Firebase project.
Note that if you do this, you have to then set up the Blaze pricing plan in the Firebase console in order for your project to continue working after the $300 credit is exhausted.
I want to follow a codelab to learn about Firebase. Can you give me a temporary billing account?
نه متاسفم You can use the Firebase emulator for development without having a Cloud Billing account. Alternatively, try applying for a Google Cloud free trial . If you're still having trouble paying your bill because of this change, contact Firebase Support.
I'm worried I'm going to rack up a huge bill.
You can set up budget alerts in the Google Cloud console to help control costs. Also, you can set limits on the number of billed instances created for each of your functions. To get an idea of costing for typical scenarios, see the Cloud Functions Pricing examples.
To use extensions, you will need to upgrade to the Blaze pricing plan. You will be charged a small amount (typically around $0.01 per month for the Firebase resources required by each extension you install (even if they are not used), in addition to any charges associated with your use of Firebase services.
Cloud Storage for Firebase pricing
How do I predict how much I will be billed for upload and download operations?
Visit the Firebase Pricing page and use the Blaze 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.
What happens if I exceed Spark plan upload, download or storage limits for Cloud Storage for Firebase ?
When you exceed limits for Cloud Storage in a project on the Spark plan, the result depends on the type of limit that you exceed:
If you exceed the GB stored limit, you will not be able to store any more data in that project unless you remove some of the data stored or upgrade to a plan that provides more storage space, or unlimited storage space.
If you exceed the GB downloaded limit, your app will not be able to download more data until the next day (starting at midnight, US Pacific Time), unless you upgrade to a plan with less restrictive limits, or with no limits.
If you exceed the upload or download operations limit, your app will not be able to upload or download more data until the next day (starting at midnight, US Pacific Time), unless you upgrade to a plan with less restrictive limits, or with no محدودیت ها
حریم خصوصی
Where can I find information about privacy and security in Firebase?
Do the Firebase SDKs log any usage/diagnostic information outside of Analytics?
بله. This is currently 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, on GitHub
A/B Testing
A/B Testing : How many experiments can I create and run?
You are allowed up to 300 experiments per project, which could consist of up to 24 running experiments, with the rest as draft or completed.
A/B Testing : Why can't I view my experiments after unlinking and re-linking my project to Google Analytics?
Linking to a different Google Analytics property will cause you to lose access to experiments created beforehand. To regain access to a previous experiment, re-link your project to the Google Analytics property that was linked when the experiment was created.
A/B Testing : Why do I receive a "Project not linked to Google Analytics" message when creating a Remote Config experiment?
If you've already linked Firebase and Google Analytics , but still see a message that Google Analytics is not linked, make sure that an Analytics stream exists for all apps in your project. Currently, all apps in a project must be connected to a Google Analytics stream to use A/B Testing.
You can find the list of all active streams on the Google Analytics integration details page within the Firebase console, accessed from settingsProject Settingschevron_rightIntegrationschevron_rightGoogle Analyticschevron_rightManage .
Creating a Google Analytics stream for any app that does not have one should resolve the issue. There are a few ways to create streams for missing apps:
If you only have one or two apps missing an associated Google Analytics stream, you can choose one of the following methods to add a Google Analytics stream:
Delete and re-add any app without an active stream in the Firebase console.
From the Google Analytics console , select Admin , click Data Streams , then click Add stream , add the missing app's details, and click Register app .
If you have more than a few missing app streams, unlinking and relinking your Google Analytics property is the fastest and most efficient way to create the missing app streams:
From settingsProject Settings , select Integrations .
Within the Google Analytics card, click Manage to access Firebase and Google Analytics settings.
Make a note of the Google Analytics Property ID and the Linked Google Analytics account .
Click more_vertMore and select Unlink Analytics from this project .
Review the warning that appears (don't worry here; you will relink the same property in the next step), then click Unlink Google Analytics .
When unlinking is complete, you'll be redirected to the Integrations page.
Within the Google Analytics card, click Enable to begin the relinking process.
Select your Analytics account from the Select account list.
Next to Automatically create a new property in this account , click editEdit and, from the Analytics property list that appears, select your property ID.
A list of all apps in your project appears. Existing stream mappings for each app are listed, and apps that do not have a stream will have one created for them.
Click Enable Google Analytics to relink the property.
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.
For Android projects : Add the dependency for the Google Mobile Ads SDK to your build.gradle file: implementation 'com.google.android.gms:play-services-ads:23.3.0'
Analytics : Why is Google Analytics a recommended part of using Firebase products?
Google Analytics is a free and unlimited analytics solution that works with Firebase features to deliver powerful insights. It enables you to view event logs in Crashlytics , notification effectiveness in FCM , deep link performance for Dynamic Links , and in-app purchase data from Google Play . It powers advanced audience targeting in Remote Config , Remote Config personalization, and more.
Google Analytics acts as a layer of intelligence in the Firebase console to provide you with more actionable insights about how to develop a high quality app, grow your user base, and earn more money.
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 your Google Analytics data is shared in your project settings anytime. Learn more about Data 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:
تنظیمات اشتراک داده
Data retention settings
Time zone and currency settings
To update your property settings, follow these steps:
In the Firebase console, go to your settings > Project settings .
Go to the Integrations tab, and then in the Google Analytics card, click Manage or View link .
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 the Analytics data will not 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 the Firebase 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 about linking a Google Analytics property to your Firebase project.
Analytics : If my Analytics property was deleted, can I link a new Google Analytics property to my Firebase project and start using Analytics again?
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 about linking 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:
Crashlytics — You can no longer see crash-free users, breadcrumb logs, and/or velocity alerts.
Cloud Messaging and In-App Messaging — You can no longer use targeting, campaign metrics, audience segmentation, and analytics labels.
Remote Config — You can no longer use targeted configurations or Personalization.
A/B Testing — You can no longer use A/B Testing since the experiment measurement is supplied by Google Analytics.
Dynamic Links — Any feature that relies on data from Google Analytics will be disrupted.
In addition, the following integrations will be affected:
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 an audience 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
Firebase 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.
منطقه
کد
پس از میلاد
آندورا
AE
امارات متحده عربی
AF
افغانستان
AG
آنتیگوا و باربودا
AL
آلبانی
AM
ارمنستان
AO
آنگولا
AR
آرژانتین
AS
ساموآی آمریکایی
AT
اتریش
AU
استرالیا
AW
آروبا
AZ
آذربایجان
BA
بوسنی و هرزگوین
BB
باربادوس
BD
بنگلادش
BE
بلژیک
BF
بورکینافاسو
BG
بلغارستان
بی جی
بنین
BM
برمودا
BN
برونئی دارالسلام
BO
بولیوی
BR
برزیل
BS
باهاما
BT
بوتان
BW
بوتسوانا
توسط
بلاروس
BZ
بلیز
CA
کانادا
سی دی
کنگو، (کینشاسا)
CF
جمهوری آفریقای مرکزی
CG
کنگو (برازاویل)
CH
سوئیس
CI
ساحل عاج
CK
جزایر کوک
CL
شیلی
سی ام
کامرون
CO
کلمبیا
CR
کاستاریکا
CV
کیپ ورد
CW
کوراسائو
CY
قبرس
CZ
جمهوری چک
DE
آلمان
دی جی
جیبوتی
DK
دانمارک
DM
دومینیکا
انجام دهید
جمهوری دومینیکن
DZ
الجزایر
EC
اکوادور
EG
مصر
ES
اسپانیا
ET
اتیوپی
FI
فنلاند
اف جی
فیجی
FK
جزایر فالکلند (مالویناس)
FM
میکرونزی، ایالات فدرال
FO
جزایر فارو
FR
فرانسه
GA
گابن
گیگابایت
انگلستان
جی دی
گرانادا
جنرال الکتریک
گرجستان
GF
گویان فرانسه
جی جی
گرنزی
GH
غنا
GI
جبل الطارق
GL
گرینلند
جنرال موتورز
گامبیا
GP
گوادلوپ
GQ
گینه استوایی
GR
یونان
GT
گواتمالا
GY
گویان
HK
هنگ کنگ، SAR چین
HN
هندوراس
منابع انسانی
کرواسی
HT
هائیتی
HU
مجارستان
شناسه
اندونزی
IE
ایرلند
IL
اسرائیل
IM
جزیره من
در
هند
IQ
عراق
IT
ایتالیا
JE
جرسی
JM
جامائیکا
JO
اردن
JP
ژاپن
KE
کنیا
KG
قرقیزستان
KH
کامبوج
KM
کومور
KN
سنت کیتس و نویس
KR
کره (جنوبی)
KW
کویت
KY
جزایر کیمن
KZ
قزاقستان
لس آنجلس
لائوس PDR
LB
لبنان
LC
سنت لوسیا
LI
لیختن اشتاین
LK
سریلانکا
LS
لسوتو
آن
لیتوانی
LU
لوکزامبورگ
LV
لتونی
LY
لیبی
MA
مراکش
MD
مولداوی
من
مونته نگرو
MF
سن مارتین (بخش فرانسوی)
ام جی
ماداگاسکار
MK
مقدونیه، جمهوری
MM
میانمار
MN
مغولستان
MO
ماکائو، SAR چین
اماس
مونتسرات
MT
مالت
MU
موریس
مگاوات
مالاوی
MX
مکزیک
من
مالزی
MZ
موزامبیک
NA
نامیبیا
NC
کالدونیای جدید
NE
نیجر
NF
جزیره نورفولک
NG
نیجریه
NI
نیکاراگوئه
NL
هلند
نه
نروژ
NP
نپال
NZ
نیوزلند
OM
عمان
PA
پاناما
PE
پرو
PG
پاپوآ گینه نو
PH
فیلیپین
PK
پاکستان
PL
لهستان
PM
سنت پیر و میکلون
روابط عمومی
پورتوریکو
PS
سرزمین فلسطین
PT
پرتغال
PY
پاراگوئه
QA
قطر
RE
رئونیون
RO
رومانی
RS
صربستان
RU
فدراسیون روسیه
RW
رواندا
SA
عربستان سعودی
SC
سیشل
SE
سوئد
SG
سنگاپور
SH
سنت هلنا
SI
اسلوونی
SK
اسلواکی
SL
سیرالئون
SN
سنگال
SR
سورینام
ST
سائوتومه و پرنسیپ
SV
السالوادور
SZ
سوازیلند
TC
جزایر تورکس و کایکوس
TG
توگو
TH
تایلند
TL
تیمور شرقی
TM
ترکمنستان
به
تونگا
TR
ترکیه
TT
ترینیداد و توباگو
TW
تایوان، جمهوری چین
TZ
تانزانیا، جمهوری متحده
UA
اوکراین
UG
اوگاندا
ایالات متحده
ایالات متحده آمریکا
UY
اروگوئه
UZ
ازبکستان
VC
سنت وینسنت و گرنادین
VE
ونزوئلا (جمهوری بولیوار)
VG
جزایر ویرجین بریتانیا
VI
جزایر ویرجین، ایالات متحده
VN
ویتنام
WS
ساموآ
بله
یمن
YT
مایوت
ZA
آفریقای جنوبی
ZM
زامبیا
ZW
زیمبابوه
Firebase 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:
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 below 50% imply many sent SMS but few successful logins, which is a common indicator of bad actors and SMS traffic pumping.
Use SMS Region Policy to either deny SMS regions with low success rates, or only allow certain regions if your app is only intended for distribution in certain markets.
Limit your authorized authentication domains
Use the Authentication settings dashboard to manage authorized domains. The localhost domain is added by default to the approved authentication domains to simplify development. Consider removing localhost from the authorized domains in your production project to prevent bad actors from running code on theirlocalhost 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.
Remember that you need to enforce App Check for Authentication in the Firebase console (consider monitoring traffic before enforcing). Also, double check your reCAPTCHA Enterprise approved 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).
Firebase 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.
Firebase 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)
Make sure that Google sign-in is properly enabled as an authentication provider:
Within the Sign in method tab, disable and then re-enable the Google sign-in method (even if it's already enabled):
Open the Google sign-in method, disable it, and then click Save .
Re-open the Google sign-in method, enable it, and then click Save .
Also, in the Google sign-in provider configuration of the Authentication section, make sure that the OAuth client ID and secret match the web client displayed in the Credentials page of the Google Cloud console (look in the OAuth 2.0 Client IDs section).
Firebase 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 the list of authorized domains for 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:
If you use Hosting -provided Auth helpers to log users in with the Authentication JS SDK, then Firebase automatically obtains your API key with the rest of your Firebase configuration each time you deploy to Firebase Hosting . Make sure that the authDomain in your web app firebaseConfig is properly configured to use one of the domains for that Hosting site. You can verify this by going to https:// authDomain __/firebase/init.json , and checking that the projectId matches that from your firebaseConfig .
If you self-host the sign-in code , then you can use a __/firebase/init.json file to provide the Firebase configuration to the self-hosted Authentication JS SDK Redirect helper. The API key and the projectId listed in this config file should match your web app firebaseConfig .
Check to make sure this API key hasn't been deleted: Go to the APIs & Services > Credentials panel in the Google Cloud console where all the API keys for your project are listed.
If the Browser key has not been deleted, check the following:
If you self-host the sign-in code, make sure the API key listed in your __/firebase/init.json file matches the API key in the Cloud console. Correct the key in the file, if necessary, then redeploy your app.
If the Browser key has been deleted, you can have Firebase generate a new API key for you: In the Firebase console, go to settings > Project settings , then in the Your apps section, click on your web app. This action automatically creates an API key that you can see in the SDK setup and configuration section for your web app.
Note that in the Cloud console this new API key will not be called Browser key ; instead, it will be the same name as your Firebase Web App's nickname. If you decide to add API restrictions to this new API key, make sure the Firebase Authentication API is in the list of allowed APIs.
Once your new API key is created, complete the applicable steps below:
If you use reserved Hosting URLs , then redeploy your app to Firebase so that it can automatically obtain the new API key with the rest of your Firebase configuration.
If you self-host the sign-in code , copy the new API key and add it to your __/firebase/init.json file, then redeploy your app.
Firebase Authentication : How do I manually construct an OAuth web client??
Open the Credentials page of the Google Cloud console.
At the top of the page, select Create credentials > OAuth client ID .
If you're prompted to configure your consent screen, follow the on-screen instructions, and then continue with the following steps of this FAQ.
Create the OAuth web client:
For the Application Type , select Web application .
For the Authorized JavaScript Origins , add the following:
http://localhost
http://localhost:5000
https:// PROJECT_ID .firebaseapp.com
https:// PROJECT_ID .web.app
For the Authorized Redirect URIs , add the following:
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. روی ذخیره کلیک کنید.
Firebase 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:
If the OAuth brand name is available, then the %APP_NAME% in the email template will be the OAuth brand name (same as pre-December 2022 behavior).
If the OAuth brand name is not available, here's how the %APP_NAME% in the email template is determined:
For web apps , the %APP_NAME% will be the default Firebase Hosting site name (the value preceding .firebaseapp.com and .web.app and usually the Firebase project ID).
For mobile apps:
If the Android package name or iOS bundle ID is present in the request, then the %APP_NAME% will be the app name used in the Play Store or App Store (respectively).
Otherwise, the %APP_NAME% will be the default Firebase Hosting site name (the value preceding .firebaseapp.com and .web.app and usually the Firebase project ID).
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
Cloud Functions runtime support
How do I upgrade to the latest supported version of Node.js?
How can I make sure I deployed my functions to a specific Node.js runtime?
In the Firebase console, go to the functions dashboard , select a function, and check the function's language under Additional details .
I use Firebase Extensions. Will I be affected by Cloud Functions runtime updates?
بله. Since extensions use Cloud Functions , the runtime of your extensions will need to be updated on the same timeline as Cloud Functions.
We recommend that you periodically update to the latest version of each extension installed in your project. You can upgrade your projects' extensions via the Firebase console or Firebase CLI .
Cloud Messaging
Cloud Messaging : What's the difference between the Notifications composer and Cloud Messaging ?
Firebase Cloud Messaging provides a complete set of messaging capabilities through its client SDKs and HTTP and XMPP server protocols. For deployments with more complex messaging requirements, FCM is the right choice.
The Notifications composer is a lightweight, serverless messaging solution built on Firebase Cloud Messaging . With a user-friendly graphical console and reduced coding requirements, the Notifications composer lets users easily send messages to reengage and retain users, foster app growth, and support marketing campaigns.
قابلیت ها
Notifications composer
Cloud Messaging
هدف
Single device
Clients subscribed to topics (ie weather)
Clients in predefined user segment (app, version, language)
Clients in specified analytics audiences
Clients in device groups
Upstream from client to server
نوع پیام
Notifications up to 2kb
Data messages up to 4kb
تحویل
فوری
Future client device local time
تجزیه و تحلیل
Built-in Notifications analytics collection and funnel analytics
Cloud Messaging : Apple announced they're deprecating the legacy binary protocol for APNs. آیا لازم است کاری انجام دهم؟
No. Firebase Cloud Messaging switched to the HTTP/2-based APNs protocol in 2017. If you are using FCM to send notifications to iOS devices, there should be no action required on your part.
Cloud Messaging : Do I need to use other Firebase services in order to use FCM ?
You can use Firebase Cloud Messaging as a standalone component, in the same manner as you did with GCM, without using other Firebase services.
Cloud Messaging : I am an existing Google Cloud Messaging (GCM) developer. Should I move to Firebase Cloud Messaging ?
FCM is the new version of GCM under the Firebase brand. It inherits GCM's core infrastructure, with new SDKs to make Cloud Messaging development easier.
Benefits of upgrading to FCM SDK include:
Simpler client development. You no longer have to write your own registration or subscription retry logic.
An out-of-the-box notification solution. You can use the Notifications composer, a serverless notifications solution with a web console that lets anyone send notifications to target specific audiences based on insights from Google Analytics.
To upgrade from GCM SDKs to FCM SDKs, see the guides for migrating Android and iOS apps.
Cloud Messaging : Why do my targeted devices apparently fail to receive messages?
When it looks like devices haven't successfully received messages, check first for these two potential causes:
Foreground message handling for notification messages . Client apps need to add message handling logic to handle notification messages when the app is in the foreground on the device. See the details for iOS and Android .
Network firewall restrictions . If your organization has a firewall that restricts the traffic to or from the Internet, you need to configure it to allow connectivity with FCM in order for your Firebase Cloud Messaging client apps to receive messages. The ports to open are:
5228
5229
5230
FCM usually uses 5228, but it sometimes uses 5229 and 5230. FCM does not provide specific IPs, so you should allow your firewall to accept outgoing connections to all IP addresses contained in the IP blocks listed in Google's ASN of 15169 .
Cloud Messaging : I have implemented onMessageReceived in my Android app, but it is not being called.
When your app is in the background, notification messages are displayed in the system tray, and onMessageReceived is not called. For notification messages with a data payload, the notification message is displayed in the system tray, and the data that was included with the notification message can be retrieved from the intent launched when the user taps on the notification.
Notifications composer: What's the difference between the Notifications composer and Cloud Messaging ?
The Notifications composer is a lightweight, serverless messaging solution built on Firebase Cloud Messaging . With a user-friendly graphical console and reduced coding requirements, the Notifications composer lets users easily send messages to reengage and retain users, foster app growth, and support marketing campaigns.
Firebase Cloud Messaging provides a complete set of messaging capabilities through its client SDKs and HTTP and XMPP server protocols. For deployments with more complex messaging requirements, FCM is the right choice.
Here's a comparison of the messaging capabilities provided by Firebase Cloud Messaging and the Notifications composer:
قابلیت ها
Notifications composer
Cloud Messaging
هدف
Single device
Clients subscribed to topics (ie weather)
Clients in predefined user segment (app, version, language)
Clients in specified analytics audiences
Clients in device groups
Upstream from client to server
نوع پیام
Notifications up to 2kb
Data messages up to 4kb
تحویل
فوری
Future client device local time
تجزیه و تحلیل
Built-in Notifications analytics collection and funnel analytics
Notifications composer: I am an existing Google Cloud Messaging (GCM) developer, and I want to use the Notifications composer. چه کار کنم؟
The Notifications composer is an out-of-the-box solution that lets anyone send notifications to target specific audiences based on insights from Google Analytics. Also, the Notifications composer provides funnel analysis for every message, allowing easy evaluation of notification effectiveness.
If you are an existing GCM developer, to use the Notifications composer you have to upgrade from GCM SDKs to FCM SDKs. See the guides for migrating Android and iOS apps.
FCM features deprecated in June 2023
Which FCM APIs were deprecated on June 20, 2023, and what should I do if I am using those APIs?
The following APIs/SDKs will be affected by the deprecation:
Server APIs
نام API
نقطه پایانی API
Impact on users
اقدام لازم است
Legacy HTTP protocol
https://fcm.googleapis.com/fcm/send
Requests to the endpoint will start failing after 6/21/2024.
API calls to FirebaseMessaging.send in the app won't trigger upstream messages to the app server after 6/21/2024.
Implement this functionality in your server logic. For example, some developers implement their own HTTP/gRPC endpoint and call the endpoint directly to send messages from their clients to the app server. See this gRPC Quick start for an example implementation of upstream messaging using gRPC.
Batch Send API
https://fcm.googleapis.com/batch
Requests to the endpoint will start failing after 6/21/2024.
These APIs will stop working after 6/21/2024 because they call the batch send API .
Upgrade to the latest Firebase Admin SDK and use the new APIs instead: sendEach()/ sendEachAsync()/send_each()/sendEachForMulticast()/sendEachForMulticastAsync()/ send_each_for_multicast() .
Note that the new APIs no longer call the deprecated batch send API, and for this reason they may create more concurrent HTTP connections than the old APIs.
Client SDKs
SDK versions
Impact on users
اقدام لازم است
GCM SDKs (deprecated in 2018)
Apps using GCM SDKs will not be able to register tokens nor receive messages from FCM after 6/21/2024.
Upgrade your Android SDK to the latest Firebase SDK if you haven't already done so.
JS SDKs version <7.0.0 (breaking change at version 7.0.0 in 2019)
Web apps using older JS SDKs will not be able to register tokens after 6/21/2024.
Upgrade your Firebase Web SDK to the latest version.
Will I see a service downgrade before June 2024?
No. You have 12 months (06/20/2023 - 06/21/2024) to migrate from the old APIs to new APIs without any service downgrade. We strongly recommend you to plan the migration as early as possible so you won't be impacted by the decommissioning of the APIs in June 2024.
After June 2024, you may see increased errors or lack of functionality when using the APIs/SDKs listed above (see the next FAQ for more information).
How and when will the deprecated APIs be shut down?
FCM will start a gradual shutdown of deprecated APIs around July 22nd, 2024. After this date, deprecated services will be subject to a "flickering" process in which increasing numbers of requests will return error responses. During the gradual ramp-down period you can expect the following behavior and error responses to increase in frequency over time:
دسته بندی
انتظار چه چیزی
Legacy HTTP protocol
Requests being rejected with HTTP code 301.
Legacy XMPP protocol
Requests being rejected with error code 302.
FCM Upstream
Messages being silently dropped by FCM backend.
Batch Send API
Requests being rejected with error code UNIMPLEMENTED and the error message "The API is deprecated."
GCM SDKs - Register Tokens
Requests being rejected with HTTP code 301.
GCM SDKs - Send Messages
Requests being rejected with error code 400 and the error message "V3 token has been deprecated."
JS SDKs version < 7.0.0
Requests being rejected with HTTP code 501.
Using server key to access Instance ID and device group management APIs
Requests being rejected with HTTP code 401.
What's the difference between OAuth 2.0 tokens and server keys?
An OAuth 2.0 token is a short-lived token derived from a service account . It's Google's standard auth model and it's more secure than static server keys.
Note that the request headers differ when you use OAuth 2.0 tokens for requests to different endpoints.
HTTP v1 API : Authorization: Bearer $oauth_token
Instance ID server API and Device group management API : Authorization: Bearer $oauth_token access_token_auth: true
Can I migrate my requests to the new API all at once?
We recommend that you slowly ramp up your traffic to the new API. If you expect to send more than 600,000 messages/min on a regular basis, contact Firebase support for instructions on how to increase quota or get recommendations on how to spread out traffic.
What's the difference between the HTTP v1 API and the legacy APIs when I send messages to topics/device groups?
Topics: you don't need to add the "/topics/" prefix to your topic target when you use the v1 API.
Device groups: You can use a group token as a token target in the HTTP v1 API. However, the HTTP v1 API doesn't return the success/failure counts in the response. We recommend that you use FCM topics or manage your device groups by yourself.
Does the HTTP v1 API support sending messages to multiple tokens in one request?
No. This feature, called "multicast" in legacy HTTP APIs, is not supported by the HTTP v1 API, which is better designed for scalability.
For use cases where end-to-end latency is critical, or where total fanout size is small (fewer than 1 million), Google recommends sending multiple separate requests using the HTTP v1 API. The HTTP v1 API over HTTP/2 performs similarly for 99.9% of multicast requests (sending < 100 tokens). For outlier use cases (sending 1000 tokens), it achieves up to a third of the throughput rate, so additional concurrency is needed to optimize for this atypical use case. Users can experience more reliability and availability with the HTTP v1 API than with legacy multicast.
For use cases where throughput and egress bandwidth are prioritized or where total fanout size is large (greater than 1 million), Google recommends topic messaging. While topic messaging requires a one-time action to subscribe recipients to a topic, it offers up to a 10,000 QPS per project fanout rate without a maximum limit on topic size.
What versions of the Firebase Admin SDK have the new APIs?
پلت فرم
Firebase Admin SDK version
Node.js
>=11.7.0
پایتون
>=6.2.0
جاوا
>=9.2.0
برو
>=4.12.0
دات نت
>=2.4.0
What's the difference between the batch send API and the HTTP v1 API?
The FCM batch send API uses the same message format and authentication mechanism as the HTTP v1 API. However, it uses a different endpoint. If you want to improve efficiency, you should consider using HTTP/2 to send multiple requests over the same HTTP connection to the HTTP v1 API.
What should I do if I can't access my project?
Please reach out to the Google Cloud support team for help.
Can new projects enable the legacy Cloud Messaging API?
No. Starting from 5/20/2024, new projects will no longer be allowed to enable our legacy APIs.
FCM quotas and limits
I need to notify a large customer base within 2 minutes.
Unfortunately, this use case cannot be supported. You must spread your traffic out over 5 minutes.
My app notifies users of events. The messages must be delivered immediately to support my business model. Can I get more quota?
Unfortunately, we cannot grant quota increases for this reason. You must spread your traffic out over 5 minutes.
My messages are about scheduled events and I need to send all my traffic at the top of the hour.
We recommend that you start sending the notifications at least 5 minutes prior to the event.
How long will it take for my quota request to be fulfilled?
This depends a bit on your use of FCM. In any case, you can expect an answer in a few business days. In some cases, there may be some back-and-forth regarding your usage of FCM and various circumstances, which can prolong the process. If all requirements are met, most requests will be handled within 2 weeks.
429s are hard for me / my business to deal with. Can I get an exemption or more quota to avoid getting 429s?
While we understand that quota limits can be challenging, quotas are vital to keeping the service reliable and we can't grant exemptions.
Can I get more quota for a temporary event?
You may request additional quota to support an event lasting up to 1 month. File the request at least 1 month in advance of the event and with clear details on when the event starts and ends, and FCM will make every practical effort to fulfill the request (no increase can be guaranteed). These quota increases will be reverted after the event's end date.
Is my current quota subject to change?
While Google will not do so lightly, quotas may be changed as needed to protect the integrity of the system. When possible, Google will notify you in advance of such changes.
Cloud Storage for Firebase
Cloud Storage for Firebase : Why can't I use Cloud Storage for Firebase ?
Cloud Storage for Firebase creates a default bucket in the App Engine no-cost tier. This allows you to quickly get up and running with Firebase and Cloud Storage for Firebase , without having to put in a credit card or enable a Cloud Billing account. It also allows you to easily share data between Firebase and a Google Cloud project.
There are, however, two known cases where this bucket cannot be created and you will be unable to use Cloud Storage for Firebase :
A project imported from Google Cloud which had a App Engine Master/Slave Datastore application.
A project imported from Google Cloud which has domain prefixed projects. For example: domain.com:project-1234 .
There are currently no workarounds to these issues, and we recommend that you create a new project in the Firebase console and enable Cloud Storage for Firebase in that project.
Cloud Storage for Firebase : Why do I get error code 412 responses about service account permissions and failed service account operations when using the Cloud Storage for Firebase API?
It's likely you're getting 412 error codes either because the Cloud Storage for Firebase API is not enabled for your project or a necessary service account is missing the required permissions.
Cloud Storage for Firebase : On Spark plan projects, can I store executable files?
For no-cost (Spark) plan projects, Firebase blocks uploads and hosting of certain executable file types for Windows, Android and Apple by Cloud Storage for Firebase and Firebase Hosting . این سیاست برای جلوگیری از سوء استفاده در پلتفرم ما وجود دارد.
Serving, hosting and file uploads of disallowed files are blocked for all Spark projects created on or after Sept 28th, 2023. For existing Spark projects with files uploaded before that date, such files can still be uploaded and hosted.
This restriction applies to Spark plan projects. Projects on the pay as you go (Blaze) plan are not affected.
The following file types cannot be hosted on Firebase Hosting and Cloud Storage for Firebase :
Windows files with .exe , .dll and .bat extensions
Android files with .apk extension
Apple platform files with .ipa extension
چه کاری باید انجام دهم؟
If you still want to host these file types after September 28th, 2023:
For Hosting: upgrade to the Blaze plan before you can deploy these file types to Firebase Hosting via the firebase deploy command.
For Storage: upgrade to the Blaze plan to upload these file types to the bucket of your choice using the GCS CLI, the Firebase console, or Google Cloud console.
Use Firebase tools to manage your Firebase Hosting and Cloud Storage resources.
For managing resources in Firebase Hosting , use the Firebase console to delete releases according to this guide .
For managing resources in Cloud Storage , navigate to the Storage product page in your project.
On the Files tab, locate disallowed files to delete in your folder hierarchy, then select them using the checkbox next to the filename(s) on the left-hand side of the panel.
Click Delete , and confirm the files were deleted.
Cloud Storage for Firebase : Why do I see an unexpected increase in upload and download operations?
Previously, download and upload requests to the Cloud Storage for Firebase API were not being counted properly. We have taken steps to fix this issue, starting from September 15, 2023.
For Blaze users, upload and download operations will start counting towards your monthly bill. For Spark users, they will start counting towards your monthly free limit.
We recommend monitoring your Usage page for any increases that may count towards your limits.
Cloud Storage for Firebase : Why do I see new service account IDs associated with 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 service account that Cloud Storage for Firebase uses 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 . As of September 19, 2022, this service account is no longer supported.
You can view all service accounts associated with your project in the Firebase console, on the Service accounts tab .
Adding the new service account
If you removed the service account previously or the service account is not present in your project, you may do one of the following to add the account.
(Recommended) Automated: Use the AddFirebase REST endpoint to re-import your bucket into Firebase. You will only need to call this endpoint once, not once for each linked bucket.
We strongly discourage you from 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 in Disabling a service account .
Dynamic Links : Why does my Android app access each Dynamic Link twice?
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 to false in each of the deep link activities to clear it for the case when the activity is triggered outside the main activity.
Firebase Local Emulator Suite
Why do Emulator Suite logs show an error starting with "Multiple projectIds are not recommended in single project mode"?
This message means the 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 the firebase.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:
The default project set at the command line. By default, the project ID will be taken on startup from the project selected with firebase init or firebase use . To view the list of projects (and see which one is selected) use firebase projects:list .
تست های واحد The project ID is often specified in calls to the Rules Unit Testing library methods initializeTestEnvironment or initializeTestApp . Other testing code may initialize with initializeApp(config) .
The command line --project flag. Passing the Firebase CLI --project flag overrides the default project. You'll need to ensure the value of the flag matches the project ID in unit tests and app initialization.
Platform-specific places to check:
وب
The projectId property in your JavaScript firebaseConfig object, used in initializeApp .
اندروید
The project_id property inside the google-services.json configuration file.
Apple platforms
The PROJECT_ID property in the GoogleService-Info.plist configuration file.
To disable single project mode, update firebase.json with the singleProjectMode key:
Hosting : On Spark plan projects, can I store executable files?
For no-cost (Spark) plan projects, Firebase blocks uploads and hosting of certain executable file types for Windows, Android and Apple by Cloud Storage for Firebase and Firebase Hosting . این سیاست برای جلوگیری از سوء استفاده در پلتفرم ما وجود دارد.
Serving, hosting and file uploads of disallowed files are blocked for all Spark projects created on or after Sept 28th, 2023. For existing Spark projects with files uploaded before that date, such files can still be uploaded and hosted.
This restriction applies to Spark plan projects. Projects on the pay as you go (Blaze) plan are not affected.
The following file types cannot be hosted on Firebase Hosting and Cloud Storage for Firebase :
Windows files with .exe , .dll and .bat extensions
Android files with .apk extension
Apple platform files with .ipa extension
چه کاری باید انجام دهم؟
If you still want to host these file types after September 28th, 2023:
For Hosting: upgrade to the Blaze plan before you can deploy these file types to Firebase Hosting via the firebase deploy command.
For Storage: upgrade to the Blaze plan to upload these file types to the bucket of your choice using the GCS CLI, the Firebase console, or Google Cloud console.
Use Firebase tools to manage your Firebase Hosting and Cloud Storage resources.
For managing resources in Firebase Hosting , use the Firebase console to delete releases according to this guide .
For managing resources in Cloud Storage , navigate to the Storage product page in your project.
On the Files tab, locate disallowed files to delete in your folder hierarchy, then select them using the checkbox next to the filename(s) on the left-hand side of the panel.
Click Delete , and confirm the files were deleted.
Hosting : Why does my Hosting release history table in the Firebase console show file counts that are more than what my local project actually has?
Firebase automatically adds extra files containing metadata about the Hosting site, and these files are included in the total file count for the release.
Hosting : What's the largest file size that I can deploy to Firebase Hosting ?
Hosting has a maximum size limit of 2 GB for individual files.
We recommend storing larger files using Cloud Storage , which offers a maximum size limit in the terabyte range for individual objects.
Hosting : How many Hosting sites can I have per Firebase project?
Performance Monitoring : How many custom URL patterns can I create?
You can create up to 400 total custom URL patterns per app and up to 100 custom URL patterns per domain for that app.
Performance Monitoring : Why am I not seeing real time display of performance data?
To view real time performance data, make sure that your app uses a Performance Monitoring SDK version that's compatible with real time data processing.
iOS — v7.3.0 or later
tvOS — v8.9.0 or later
Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
Realtime Database
Realtime Database : Why was my Realtime Database reported bandwidth lower than average between September 2016 and March 2017?
For our bandwidth calculations, we normally include SSL encryption overhead (based on layer 5 of the OSI model). However, in September 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.
Realtime Database : What are the scaling limitations of the Realtime 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.
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 the Firebase console that you've exceeded your Realtime Database usage limits, you can address it based on the usage limit you've exceeded. To see your Realtime Database usage, go to the Realtime DatabaseUsage dashboard in the Firebase console.
If you're over your download limit, you can upgrade your Firebase 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:
Add queries to limit the data that your listen operations return.
Check for unindexed queries.
Use listeners that only download updates to data — for example, on() instead of once() .
Use security rules to block unauthorized downloads.
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:
Run periodic cleanup jobs.
Reduce any duplicate data in your database.
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.
Remote Config
Remote Config : Why don't fetched values change the behavior and appearance of my app?
Unless you fetch values with fetchAndActivate() , values are stored locally but not activated. To activate fetched values so that they can take effect, call activate . This design lets you control when the behavior and appearance of your app changes, because you can choose when to call activate . After you call activate , your app source code determines when updated parameter values are used.
For example, you could fetch values and then activate them the next time a user starts your app, which removes the need to delay app startup while your app waits for fetched values from the service. Changes to your app's behavior and appearance then occur when your app uses the updated parameter values.
Remote Config : I am making a lot of fetch requests while developing my app. Why doesn't my app always get the latest values from the service when it sends fetch requests?
During app development, you might want to fetch and activate configs very frequently (many times per hour) to let you rapidly iterate as you develop and test your app. To accommodate rapid iteration on a project with up to 10 developers, you can temporarily set a FirebaseRemoteConfigSettings object with a low minimum fetch interval ( setMinimumFetchIntervalInSeconds ) in your app.
Remote Config : How quickly does the Remote Config service return fetched values after my app sends a fetch request?
Devices usually receive fetched values in less than a second, and often receive fetched values in milliseconds. The Remote Config service handles fetch requests within milliseconds, but the time required to complete a fetch request will depend on the network speed of the device and the latency of the network connection used by the device.
If your goal is to make fetched values take effect in your app as soon as possible, but without creating a jarring user experience, consider adding calls to fetchAndActivate each time that your app does a full screen refresh.
Firebase User Segmentation Storage stores Firebase 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.