The popularity of Android attracts more and more developers towards android development but most of the new developers get frustrated by experiencing slow Android Studio.
I used to develop android apps in eclipse, when migrated to Android Studio it made me loose a lot of my precious development time until i discovered how to improve the performance of android studio.
Follow these two steps mentioned below, The first step will help android studio to reduce gradle build time which in turn reduces the time it takes to build a project each time for testing. The second step will improve the overall performance of android studio, this step will make android studio faster and will save your development time.
You also should learn How to fix Cannot Resolve Symbol R error in android studio.
How to reduce Gradle Build time:
Gradle build is time consuming and you can improve it by enabling gradle offline mode. Every time when we want to test or run a project on a physical device / emulated device android studio creates an apk file with the help of gradle. In android studio gradle is responsible for checking dependencies, collecting all the resources and files required for the project in a single file called apk, which is then copied and installed on a live android device.
Before enabling gradle offline mode, you have to make sure that you have downloaded or updated all the repositories required by your project.
Steps to make Gradle Offline:
- Open settings or preferences window by clicking File > settings(in windows)/ Preferences(Mac).
- In the left menu, click Build, Execution, Deployment > Gradle.
- In Build, Execution, Deployment > Gradle window check the checkbox for Offline work.
- Click Apply or OK button to save changes.
Improve the overall Performance of Android Studio:
You can improve the performance of android studio by disabling a number of plugins which are not required for your current project and believe me there are some active plugins in your android studio which you are not using right now.
- Open settings or preferences window by clicking File > settings(in windows)/ Preferences(Mac).
- In the left menu, click Plugins.
- In Plugins window, uncheck the boxes against the plugins you are not using. If you are not sure, i have listed the plugins below which are safe to disable.
- Click Apply or OK button to save changes.
In the run for making android studio the perfect IDE and to ease the development process for android developers they have packed it with numerous plugins. But they ignored the fact that not every android developer have a lot of RAM installed on their PC’s or laptops, especially the new comers.
Although for android studio the minimum required RAM is 3 GB which almost every modern Laptop has installed on, but you should have at least have 8 GB RAM, if you don’t want your system crawling and begging for memory and performance.
Android Studio Plugins safe to disable:
These plugins are safe to disable in android studio and will not effect your project unless you are using any of these plugins, if your project requires a plugin you can safely enable it back, All you have to do is just follow the above mentioned steps.
- App Links Assistant
- hg4idea
- GitHub
- Android APK Support
- Firebase
- Subversion integration
- Android Games
- Android NDK
- CVS
- EditorConfig
- all plugins related to Firebase,
- TestNG,
- Google analytics uploader
- Google app indexing
- YAML
- Test recorder
- Settings repository
- Task management
- Terminal
That’s all, Now Enjoy android development in a fast android studio.
If you liked this, Kindly support us by sharing this on social media with your friends.