Android Studio is a full-featured and cross-platform integrated development environment (IDE) that helps you build applications for Google’s Android operating system. It is available for Windows, Linux and macOS. However, in this tutorial, we will focus on the installation of Android Studio in Ubuntu Linux. It is based on JetBrains’ IntelliJ IDEA. Android Studio includes everything that a developer needs for any Android App development.
Android Studio build system has been powered by Gradle. Gradle allows you creating multiple build variants for different devices from a single project.
This tutorial can be applied to all versions of Ubuntu-based distributions including Ubuntu 16.04, Ubuntu 18.04, Linux Mint, etc.
- 1280 x 800 minimum screen resolution.
- 2 GB of available disk space minimum, 4 GB Recommended (500 MB for IDE + 1.5 GB for Android SDK and emulator system image)
- 3 GB RAM minimum, 8 GB RAM recommended; plus 1 GB for the Android Emulator.
In order to proceed with this tutorial, you will need to create a user account with sudo rights.
Installing Java OpenJDK
Android Studio requires installing Java Development Kit. In Ubuntu, you can install Oracle Java or OpenJDK version 8 or above. In this tutorial, you will install OpenJDK. To do so, follow the steps below:
Run the command below to update your Ubuntu system package before installation:
# sudo apt update
Execute the following command to start the installation of OpenJDK 8 package:
# sudo apt install openjdk-8-jdk
But if you are interested in Java Oracle instead of OpenJDK, you can execute the command below:
# sudo apt install default-jdk
After successful completion of the installation process, confirm your installation by executing the command for testing Java version:
# java -version
You will see the output as given below.
openjdk version "1.8.0_191" OpenJDK Runtime Environment (build 1.8.0_191-8u191-b12-2ubuntu0.18.04.1-b12) OpenJDK 64-Bit Server VM (build 25.191-b12, mixed mode)
Installing Android Studio:
The simplest and easiest way to install Android Studio is by using snappy packaging. Currently, Android Studio 126.96.36.199 is a stable version. However, if you find the latest stable version, you can install it. To download and install Android Studio snap package, run the following command in your Linux terminal.
# sudo snap install android-studio --classic
After successful completion of installation, you will see the following output.
android-studio 188.8.131.52 from Snapcrafters installed
Starting Android Studio on Ubuntu:
Android Studio can be started in two ways, by using terminal or by double-clicking icon. In the terminal, you can type the following command:
On desktop, you can navigate to Activities, locate Android Studio and click the Android Studio icon.
When you will start for the first time, you will see a window asking you to Complete Installation as shown below.
Click on Do not import settings option and click OK.
Now Android Studio Setup Wizard will start. You will be asked to choose the type of setup. Click Standard and click Next.
Now after successful completion of installation. Android Studio will be loaded and you will see the welcome screen as shown below.
Congratulations…!! Here you go…you have successfully installed Android Studio on your Ubuntu Linux. Now you can develop Android applications. To start with Android applications, you can see the video tutorials for beginners.