Android Studio is the official Integrated Development Environment (IDE) for Android development, and it’s a crucial tool for building Android apps. Whether you’re a beginner eager to start your mobile development journey or an experienced developer looking to set up a new machine, getting Android Studio up and running on Ubuntu is a fundamental first step. Ubuntu, being one of the most popular Linux distributions, provides an excellent platform for Android development with Android Studio.
This detailed, beginner-friendly guide will take you through the entire process of install Android Studio on Ubuntu. We’ll break down each step in a way that’s easy to follow, ensuring you can quickly set up your development environment and start coding.
What is Android Studio?
Android Studio is a powerful IDE developed by Google for creating Android applications. It provides everything you need to build, test, and debug Android apps, including a robust code editor, an emulator, and integration with Android SDK tools. Android Studio comes with built-in support for programming languages like Java and Kotlin, making it a one-stop solution for Android development.
Some of Android Studio’s notable features include:
- Code Completion and Refactoring: Helps you write code faster with smart suggestions and allows for easy refactoring.
- Android Emulator: Test your app on virtual devices, simulating different Android environments and screen sizes.
- Integrated Version Control: Seamlessly integrate with GitHub and other version control systems to manage your code.
- Built-in Tools: Use Profiler, Device File Explorer, and other tools for performance analysis and debugging.
Why Choose Ubuntu for Android Development?
Ubuntu is a fantastic choice for Android development, and here’s why:
- Stability and Performance: Ubuntu is known for its stability and performance, which is essential when working on large Android projects.
- Comprehensive Package Management: Ubuntu’s package manager, APT, makes it easy to install software and libraries.
- Open Source and Free: Like Android Studio, Ubuntu is free and open-source, making it accessible to everyone.
- Large Developer Community: The Ubuntu community is active and offers a wealth of resources for developers, making it easy to find support for your development needs.
These benefits, combined with Android Studio’s robust features, make Ubuntu an excellent platform for Android app development.

System Requirements for Installing Android Studio
Before you begin, make sure your Ubuntu machine meets the following system requirements for Android Studio:
- Operating System: Ubuntu 18.04 or later.
- RAM: At least 8 GB of RAM (4 GB minimum).
- Disk Space: A minimum of 4 GB of free disk space, though more is recommended for storing your projects and Android emulators.
- Processor: Intel Core i5 or higher (64-bit recommended).
- Graphics: A graphics card that supports hardware acceleration for the Android Emulator.
Additionally, you should ensure that your machine is up-to-date. You can do this by running the following commands in your terminal:
sudo apt update
sudo apt upgrade
This will ensure you have the latest updates and security patches.
Preparing Ubuntu for Android Studio Installation
Before you install Android Studio, it’s important to ensure your system is properly configured. Here are a few preparatory steps:
- Install Java Development Kit (JDK): Android Studio requires Java, so ensure that the JDK is installed. You can install OpenJDK (which is the open-source implementation of the Java Platform) by running:
sudo apt install openjdk-11-jdk
To verify the installation, check the version of Java:java -version
- Enable 32-bit Libraries (If Needed): Android Studio requires certain 32-bit libraries, even on a 64-bit system. You can install these by running:
sudo apt-get install libc6:i386 lib32gcc1 lib32stdc++6 lib32z1
Once your system is prepared, you’re ready to proceed with the installation.
Method 1: Install Android Studio via APT Package Manager
One of the easiest ways to install Android Studio on Ubuntu is by using the APT package manager. This method ensures that you get the latest stable release directly from Ubuntu’s software repositories.
Step-by-Step Guide:
- Add the Official Android Studio Repository: First, add the official Android Studio repository to your package manager sources:
sudo add-apt-repository ppa:maarten-fonville/android-studio
- Update Package Lists: After adding the repository, update your package lists:
sudo apt update
- Install Android Studio: Now, install Android Studio:
sudo apt install android-studio
- Launch Android Studio: Once the installation is complete, you can start Android Studio by typing:
android-studio
You can also launch it from the application menu.
Method 2: Install Android Studio via Snap Package
Snap is a universal Linux package format that can be installed on any Linux distribution, including Ubuntu. This method is very straightforward and works well if you have Snap installed on your system.
Step-by-Step Guide:
- Install Snap (if not already installed): If Snap is not installed on your Ubuntu system, you can install it by running:
sudo apt install snapd
- Install Android Studio via Snap: After installing Snap, you can install Android Studio by running the following command:
sudo snap install android-studio --classic
The--classic
flag is necessary because Android Studio requires full system access to run properly. - Launch Android Studio: Once the installation is complete, you can launch Android Studio by typing:
android-studio
Method 3: Install Android Studio Using the .deb Package
If you prefer to manually install Android Studio, you can download the .deb
package directly from the official website and install it.
Step-by-Step Guide:
- Download the .deb Package: Go to the official Android Studio download page and download the
.deb
package for Ubuntu. - Install the .deb Package: Once the file is downloaded, navigate to the folder where the
.deb
file is located. Then, install it using the following command:sudo dpkg -i android-studio-*-*.deb
- Fix Any Missing Dependencies: If there are any missing dependencies, fix them by running:
sudo apt --fix-broken install
- Launch Android Studio: After installation, launch Android Studio by typing:
android-studio
Setting Up Android Studio for First Use
After you’ve installed Android Studio, you’ll need to set it up for the first time. Here’s how:
- Initial Setup Wizard: Upon launching Android Studio for the first time, it will guide you through an initial setup process. The wizard will download essential components, such as the Android SDK and necessary libraries.
- Choose SDK Components: The setup wizard will prompt you to select the Android SDK components to install. Make sure you install the Android SDK, Android SDK Platform-tools, and Android SDK Build-tools.
- Install Android Virtual Device (AVD): For testing your apps, you’ll need an Android Emulator. You can install an Android Virtual Device (AVD) from the AVD Manager in Android Studio.
- Check for Updates: Once everything is set up, check for any updates to Android Studio and the SDK by going to Help > Check for Updates.
Troubleshooting Installation Issues
During the installation process, you may encounter some issues. Here are a few common problems and their solutions:
- Error: “Android Studio Cannot Find JDK”: If you see this error, ensure that you’ve installed the Java Development Kit (JDK) correctly and set the
JAVA_HOME
environment variable:export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
- Emulator Not Launching: If the Android Emulator doesn’t launch, ensure that virtualization is enabled in your system’s BIOS. Additionally, check if your system supports KVM for hardware acceleration.
Conclusion:
Congratulations! You’ve successfully install Android Studio on Ubuntu machine and are now ready to start developing Android apps. Android Studio provides a comprehensive set of tools, and with its powerful features, you’ll be able to bring your ideas to life with ease.
Next Steps:
- Explore the Android Developer Documentation to learn more about the tools and how to create your first app.
- Install some essential Android Studio plugins for better functionality.
- Join the Android developer community to stay up-to-date with the latest trends.
If you encountered any issues or have questions about the setup process, feel free to leave a comment below. Happy coding!
If this guide helped you get Android Studio running on Ubuntu, share it with other developers who might benefit! You can also explore more installation guide on our site to enhance your skills.
Read Also : How to Install VS Code on Ubuntu?