Android App Performance Metrics
- Amit Shekhar
- Published on
I am Amit Shekhar, I have taught and mentored many developers, and their efforts landed them high-paying tech jobs, helped many tech companies in solving their unique problems, and created many open-source libraries being used by top companies. I am passionate about sharing knowledge through open-source, blogs, and videos.
Before we start, I would like to mention that, I have released a video playlist to help you crack the Android Interview: Check out Android Interview Questions and Answers.
In this blog, we will learn about the metrics that we should measure continuously while android application development.
Frames Per Second
This metric is very important as it tells, how your android application is being experienced by the end user. So tracking this metric and improving will lead to a better user experience. If the FPS is coming below 60, the end user will see your application lagging.
How do you measure this metric?
- On your mobile device, go to
Settings -> Developer Options.
- In the Monitoring section, select
Profile GPU Rendering.
- In the Profile GPU Rendering popup, choose
On screen as barsto overlay the graphs on the screen of your mobile device.
- Go to the app that you want to profile.
This metric is important as it will tell you how much CPU is being used by your application. More the CPU consumption, more the battery consumption. So, you must track and improve this metric.
The real-time CPU usage can be directly seen in the monitor tab of the Android Studio.
The metric tells you about how much memory is being used by your application while running. If your application is taking more memory, then it can easily go out of memory error. So, you should track and reduce memory usage as much as possible. This metric can also be tracked from the Android Studio’s monitors tab. Soon I will write an article on how to reduce memory usage.
Network Traffic metric tells you about the network request being made from your apps. So, monitor all the traffic generated by your app, make sure to remove all unnecessary requests and stop draining your user’s data. The transmit and receive of data can be tracked from the Android Studio’s monitors tab.
There are many ways to measure this metric like by adding the
NetworkInterceptor in the OkHttpClient (How to add?).
This metric is also very important as using more space on disk leads to the uninstall. So, reducing disk memory consumption leads to the higher user retention time. So start tracking and keep reducing the disk memory usage.
So, now we know the metrics that we should measure continuously while android application development.
Master Kotlin Coroutines from here: Mastering Kotlin Coroutines
That's it for now.
You can connect with me on: