Android Studio is the official Integrated Development Environment (IDE) for Android app development, based on IntelliJ IDEA. It provides a robust environment for coding, testing, and deploying Android apps. This guide will walk you through the steps to install Android Studio on an Ubuntu system.
Prerequisites
Before we start, make sure your system meets the following requirements:
- A 64-bit version of Ubuntu 18.04 or later
- 4 GB RAM minimum, 8 GB RAM recommended
- 2 GB of available disk space minimum, 4 GB recommended (500 MB for IDE + 1.5 GB for Android SDK and emulator system image)
- A 64-bit CPU
Step 1: Install Java Development Kit (JDK)
Android Studio requires the Java Development Kit (JDK). To install it, open a terminal and execute the following commands:
sudo apt update
sudo apt install openjdk-11-jdk
To verify the installation, you can check the Java version:
java -version
Step 2: Download Android Studio
1. Download Android Studio
Go to the official Android Studio download page and download the latest version of Android Studio for Linux:
2. Extract and Install Android Studio
tar -xzf android-studio-*-linux.tar.gz
sudo mv android-studio /opt/
/opt/android-studio/bin/studio.sh
replace * with your downloaded android studio version.
Step 3: Configure Android Studio
When you run the studio.sh
script, the Android Studio setup wizard will start. Follow these steps:
1. Welcome to Android Studio Setup: Click Next
.
2. Install Type: Choose the Standard
option for the default settings and click Next
.
3. Verify Settings: Review your settings and click Next
.
4. License Agreement: Choose Accept
and Click Next
5. Emulator Settings: Click Finish
6. Downloading components: Now it will start to download components.
After downloading Finish button will appear . Click on Finish
button.
7. Android Studio Welcome Window: Now it will appear with Android Studio Welcome window. Click on New Project
.
8. Project: Now choose ‘No Activity
’.
9. New Project Setup: Now it will ask you to create a project. Remain this as it is and click on Finish
.
10. Completing Request Actions: Now, It will download and install SDK platforms
After downloading and Installing of SDK Platform click on Finish
.
Step 4 : Launch the emulator in Android Studio
1. Android Studio window will open.
2. It will start to download packages. You can check these downloading packages on clicking left side button mention in the below image.
After finishing of downloading wait for the ‘BUILD SUCCESSFUL‘ message.
3. Now, click on ‘Device Manager
’. Refer to the red arrow in the upper right side of the screenshot below.
It will show list of android emulator present on the Device Manager.
4. Click the “Play” button to launch the emulator.
5. Congratulations! Your emulator has successfully launched in Android Studio.
Step 5: Set Up Environment Variables
1. Open .bashrc File
vim ~/.bashrc
2. Add the Following Lines
export ANDROID_HOME=$HOME/Android/Sdk
export PATH=$PATH:$ANDROID_HOME/emulator
export PATH=$PATH:$ANDROID_HOME/tools
export PATH=$PATH:$ANDROID_HOME/tools/bin
export PATH=$PATH:$ANDROID_HOME/platform-tools
3. Apply the Changes
source ~/.bashrc
FAQ: Installing Android Studio on Ubuntu 24.04
- Q: How do I install Android Studio on Ubuntu 24.04?
A: Follow the step-by-step guide in the article, which includes installing JDK, downloading Android Studio, extracting and installing it, and configuring the environment. - Q: Can I install Android Studio on Ubuntu 24?
A: Yes, the installation process for Ubuntu 24.04 should work for Ubuntu 24 as well. - Q: How do I install the Android SDK on Ubuntu 24.04?
A: The Android SDK is installed automatically when you install Android Studio. Follow the guide to install Android Studio, which includes the SDK. - Q: Is there an Android emulator for Ubuntu 24.04?
A: Yes, Android Studio includes an emulator. After installation, you can set up and run the emulator from within Android Studio. - Q: How do I install Java for Android Studio on Ubuntu 24.04?
A: Use the commandsudo apt install openjdk-11-jdk
to install the Java Development Kit. - Q: Can I install Android Studio from a .tar.gz file on Ubuntu?
A: Yes, the guide provides instructions for extracting and installing Android Studio from a .tar.gz file. - Q: How do I set up ANDROID_HOME on Ubuntu?
A: Add the following line to your ~/.bashrc file:export ANDROID_HOME=$HOME/Android/Sdk
- Q: Is there a way to install Android Studio using apt?
A: Android Studio is not available in the default Ubuntu repositories. Follow the manual installation process described in the article. - Q: How do I install Android Studio on Linux?
A: The process for Ubuntu 24.04 described in this article should work for most Linux distributions, with minor adjustments if needed. - Q: Can I develop Android apps on Ubuntu?
A: Yes, installing Android Studio on Ubuntu allows you to develop Android applications. - Q: How do I download Android Studio for Ubuntu?
A: Visit the official Android Studio download page and select the Linux version. - Q: How do I install Android Studio from the terminal?
A: You can download the .tar.gz file and use terminal commands to extract and install it, as described in the article. - Q: What if the Android Studio setup wizard is not downloading components?
A: Ensure you have a stable internet connection. If issues persist, try restarting the setup wizard or check your firewall settings. - Q: How do I set up the Android Studio environment variables on Ubuntu?
A: Edit your ~/.bashrc file to include the necessary export commands for ANDROID_HOME and PATH, as shown in the article. - Q: Can I install Android apps on Ubuntu?
A: While Android Studio is for developing apps, you can run Android apps on Ubuntu using emulators or tools like Anbox. - Q: How do I install Android Studio in Spanish? (Instalar Android Studio en Ubuntu)
A: The installation process is the same regardless of language. You can change the language settings within Android Studio after installation. - Q: How do I install Android Studio in Russian? (Установка Android Studio Ubuntu)
A: Follow the same installation process, then change the language settings in Android Studio preferences. - Q: What are the system requirements for Android Studio on Ubuntu?
A: The article lists the prerequisites, including a 64-bit Ubuntu version, minimum 4GB RAM, and at least 2GB of available disk space. - Q: How do I update Android Studio on Ubuntu?
A: Android Studio typically notifies you of updates. You can also check for updates in the IDE under Help > Check for Updates. - Q: How do I run the Android Studio setup wizard?
A: The setup wizard runs automatically when you first launch Android Studio after installation. - Q: Is there a guide for installing Android Studio on Mac?
A: Yes! If you’re using a Mac, check out this guide on installing Android Studio Ladybug (2024) on Mac M1, M2, M3 here.
Conclusion
Congratulations! You have successfully installed Android Studio on your Ubuntu system. You can now start developing Android applications using the powerful features of Android Studio. Happy coding!