Challenge - 5 Problems
Firebase Setup Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate2:00remaining
Firebase Project Initialization
What is the first step to connect your Android app to a Firebase project?
Attempts:
2 left
💡 Hint
Think about what you need to do before adding code or files.
✗ Incorrect
You must first create a Firebase project in the Firebase console and register your Android app using its package name. This generates the configuration file needed for your app.
❓ ui_behavior
intermediate2:00remaining
Placing google-services.json
Where should you place the google-services.json file in your Android project for Firebase to work correctly?
Attempts:
2 left
💡 Hint
It should be where your app module files are.
✗ Incorrect
The google-services.json file must be placed inside the app/ directory (the module folder) so the Firebase Gradle plugin can find it during build.
📝 Syntax
advanced2:00remaining
Adding Firebase Plugin in build.gradle
Which line correctly applies the Firebase plugin in your app-level build.gradle file?
Android Kotlin
plugins {
id("com.android.application")
// Add Firebase plugin here
}Attempts:
2 left
💡 Hint
Use the plugins block syntax with the correct plugin id.
✗ Incorrect
The correct plugin id to apply in the plugins block is "com.google.gms.google-services". The other options are either old syntax or incorrect plugin ids.
❓ lifecycle
advanced2:00remaining
Firebase Initialization Timing
When is the best time to initialize Firebase in your Android app to ensure it works properly?
Attempts:
2 left
💡 Hint
Think about when Firebase services should be ready for use.
✗ Incorrect
Initializing Firebase in the Application class's onCreate() ensures Firebase is ready before any activity or UI loads.
🔧 Debug
expert2:00remaining
Debugging Missing Firebase Configuration
Your app crashes with a runtime error saying "Default FirebaseApp is not initialized". Which of the following is the most likely cause?
Attempts:
2 left
💡 Hint
Check if the configuration file is correctly included.
✗ Incorrect
This error usually means the app cannot find the Firebase config file (google-services.json) or it is not placed in the correct location.