Android Crash Reporting Tutorial Using Google Firebase

Android Crash Reporting Tutorial

If you are not going to use google alpha/beta testing then you will surely face issues in getting error logs from client. There are many android devices with different android api in market and testing your app on each device is really a tough job. Using Firebase Crash Reporting you can get all crash logs with required details to fix errors, this is the Android Crash Reporting Tutorial in which we will discuss how to use Google Firebase for android crash reporting.

Open Firebase Console

Create New project, Now click on add firebase to android

Enter your project package name and optional signing certificate.

Android Crash Reporting Tutorial

It will create google-services.json file Move it into your Android app module root directory.

Android Crash Reporting Tutorial

Add following code:

In Project-level build.gradle (<project>/build.gradle):

buildscript {
dependencies {
// Add this line
classpath ''

In App-level build.gradle (<project>/<app-module>/build.gradle):

// Add to the bottom of the file
apply plugin: ''

Add following in In App-level build.gradle

compile ''

Now sync your project

Android Crash Reporting Tutorial

Now throw exception to record it on firebase interface.

Use following code in your activity to throw exception: Exception(" : My first Android non-fatal error"));

Firebase Console:

Here is my first error that logged on Firebase console.

Android Crash Reporting Tutorial

On Error click you can see it’s details, like android api, device name etc


Download Code

Leave a Reply

Your email address will not be published. Required fields are marked *