Want to run Android apps on Linux? How about play Android games? Several options are available, but the one that works the best is Anbox. This is a tool that runs your favorite Android apps on Ubuntu and other Linux distros without emulation.
Here’s how to use Anbox to run Android apps on your Linux PC today.
Meet Anbox, Your “Android in a Box”
Having access to your preferred Android apps and games brings an exciting new dimension of productivity to Linux. Mobile apps are, by design, a lot simpler than those found on desktop operating systems.
This could be just what you’re looking for to improve desktop productivity!
Meanwhile, mobile games are becoming increasingly sophisticated. It makes sense that you might want to continue playing on a different device. This is especially true considering the limited battery life of a phone or tablet.
Several macOS and Windows tools are available for running Android apps (such as Bluestacks) but this isn’t available for Linux.
Instead, to use Android apps on Linux, users should try Anbox. This is a free and open source tool designed to install and run Android apps on Linux. It’s based on the Android Open Source Project (AOSP) and offers a window-based Android environment.
Anbox uses containers to separate Android from the host operating system, enabling you to run Android games on Linux.
That’s not all; Anbox has no limits, so in theory you can run any Android app on Linux. However, while there’s no hardware virtualization, older systems will struggle with Anbox.
Which Linux Distros Support Snap?
Although free to use, Anbox comes as a snap package. This means that the binary and any dependencies are included in a single package, easing installation. Unfortunately, it means that your Linux OS cannot use Anbox unless it can unpack and install snaps.
Snap support is available for most Linux distros, including:
- Arch Linux
- Linux Mint
In Ubuntu 22.04 LTS, snap is pre-installed. You’ll find full details for your distro at the Snapcraft website.
Meanwhile, if your distro doesn’t have Snap out of the box, see our guide on how to install Snap.
Install Anbox on Ubuntu 20.04 LTS and Later
Installation of Anbox requires a system running Ubuntu 20.04 LTS or later. While Anbox could run on some previous Ubuntu versions, these are no longer supported.
First, ensure snap is installed. As you’re using a recent Ubuntu build it should be, but just in case check with:
snap find hello
This will result in a list of “hello world” snaps being displayed, confirming that snap is installed.
You can then proceed to install the beta version of Anbox:
sudo snap install
Wait while this installs then restart your computer.
How to Download and Run APK Files on Your Linux PC
With your PC rebooted, you should find Anbox available in your desktop’s menu. Click it to launch— you’ll soon see the Anbox window.
If nothing happens, or you’re stuck on a splash screen with the Starting message, cancel or wait for this to end. Then open a new terminal and enter
Next, click the icon in the menu again. A few moments later, Anbox should run, but you may need to click the icon again.
With Anbox running, you’ll see a list of the basic Android apps you can run on Linux, such as Calendar and Email. Simply left click these icons to open them; they’ll appear in new windows that you can resize as required. If you need a browser, the WebView Shell is included.
Install Android Apps From Google Play and Beyond
To add your own apps and games, all you need to do is download (or copy from another device) the appropriate APK files (What Is an APK?). These are installer files, like DEB files (or snaps) in Linux, or EXE files in Windows. If you run an APK in Ubuntu with Anbox, it will install like any other Android app.
You have two options for installing apps on Anbox:
- Install Google Play
Let’s look at them each in turn.
Sideload Android Apps on Anbox
Sideloading is relatively simple. You can use the browser and these Google Play alternatives to add software in Anbox. If you opt to sideload APKs, you’ll need to enable installation from unknown sources:
- Open the Settings menu from the apps screen
- Click Security
- Enable Unknown Sources
- Click OK to accept
The app should now be installed and ready to use.
How to Use Anbox to Install Android Apps From Google Play
If you prefer Google Play, there is a GitHub project, Anbox Playstore Installer, that makes the process of installing apps in Anbox as easy as it is on your phone or tablet.
To start, ensure your Linux system has wget installed:
sudo apt install wget curl lzip tar unzip squashfs-tools
Next, download the Anbox Play Store script:
Make it executable:
chmod +x install-playstore.sh
Then run the script:
Run Anbox if it doesn’t load automatically:
Then, set the correct permissions in Android.
- Open Settings
- Go to Apps > Google Play Services
- Tap Permissions then enable all permissions
- Repeat this for Apps > Google Play
You can now install Android apps in Anbox from Google Play.
How Run Android Apps on Linux Without Anbox
While a reliable option, Anbox isn’t the only way to run Android apps on Linux. Other Android emulators for Linux are available.
- Android Studio
There are also two Android-based operating systems compatible with x86 computers which will let you install Android apps:
Each solution has its own advantages and disadvantages.
Now You Can Run Android APKs on Linux
Anbox may have some stability issues. However, it is reassuring to know how simple it is to set up, install, and run Android apps on Linux Ubuntu with Anbox.
- Confirm your distro supports snap packages.
- Install or update the snapd service.
- Install Anbox.
- Launch Anbox from your Linux desktop.
- Download APK files and run them.
- Wait as the APK file installs.
- Click to run Android apps on your Linux desktop.
Anbox isn’t the only way to run Android on Linux distros, but we think it is the simplest.
Read the full article here