Firebase, Facebook & Google
Last updated
Last updated
Firebase is a mobile and web application development platform developed by Firebase, Inc. in 2011, now it's owned by Google. It provides a variety of tools and services to help developers build and manage mobile and web applications. Some of the main features of Firebase include:
Real-time Database: Firebase offers a real-time, cloud-based NoSQL database, which allows developers to store and sync data in real-time across all connected clients.
Authentication: Firebase provides built-in authentication for email and password, as well as support for popular identity providers like Google, Facebook, and Twitter.
Cloud Storage: Firebase offers cloud-based storage for storing and retrieving user-generated files, such as images and videos.
Cloud Functions: Firebase allows developers to run backend code in response to events triggered by Firebase features and HTTPS requests.
Hosting: Firebase provides a hosting service for web applications, which allows developers to easily deploy and serve their web content.
ML Kit: Firebase offers a set of pre-built machine learning models that can be used to add intelligent features to apps.
Analytics: Firebase provides a powerful analytics platform that allows developers to track user engagement and behavior in their apps.
Go to firebase console https://console.firebase.google.com/
2. Create your firebase account
3. Click on Add project
4. Enter your app name and then click on continue
5. Enable Google analytics for this project and then continue
6. Select default account for firebase, then add firebase
7. Your firebase project is set up
Click on your project, select android app [ IMAGE 1 ]
Register your app by adding package name, app name and sha1 certificate [IMAGE 2 ]
Then click on continue to console in the last step
go to firebase console -> project overview -> project setting [ IMAGE 3 ]
Copy SHA1 and SHA-256 key and paste it in the firebase project by add fingerprint and save the keys [ IMAGE 4,5,6 ]
Download the google-services.json file and add this file in the app code
Go to project directory -> android ->app
now add your google-services.json file here
Then to enable google login
Go to Authentication, click on get started. Then go to sign in method.
Go to google, enable the google. Add support email and then save
1. Go to https://developers.facebook.com/
2. Click on get started
3. Register your app as a Developer account
4. Click on Create app and then Select Business and continue
5. Complete the details of the app and then click on create app
6. Now complete the details and use the app id in the app code at the path
project directory\android\app\src\main\res\values\strings.xml
To create hash key
• Copy the command to create hash key
• Open command prompt
• Paste the command in cmd
• edit your path and then enter the keystore password used in the app code
• copy that hash key and paste it in the Key hashes column and continue
go to the android studio
open terminal and run the command as follow
cd android [enter]
then run the command gradlew signingReport [enter]
copy the SHA key [ SHA1 and SHA-256 ] [Variant: release ]