Can I run Android apps on Ubuntu?
Is it possible to run Android apps on Ubuntu? And I don’t mean inside an emulator, but natively, as you would with any other application installed using the Ubuntu Software Center.
9 Answers 9
You can now under Chrome run APKs, using this extension (bearing in mind it is in development for use by developers for testing apps). Here are some steps I did to get it to work
- Install from here — click ‘Add to Chrome’ This will take a while as it seems to download a crx installer weighing in at 113Mb, and another one at around 9Mb, so be patient: N.B. on my Fedora 21 build of Chromium 40 I got the error ‘Manifest file is invalid’ when trying install the extension, even after clearing data and reloading the extension. I also had issues with Ubuntu 14.04’s build of Chromium 41, so I installed Google Chrome 🙁 and that worked.
- Get a APK of the application you want to use — no, it does not seem like you can install from Google Play, you need a APK file of the app, so this is the tricky bit.
Most closed source devlopers don’t want their stuff freely distributed, so for most apps on Google Play at least you either need to use:- Use a APK for a open-source app — for testing this I tried using the x86 APK for VLC Media PLayer, which resulted in a error screen — I then tried the armv7 arc version and that worked at first and then crashed.
- Get a APK from a Android device — this easily easily be done on some rooted Android devices, on normal devices I think you can copy system app’s apks from /system/apps or somewhere — again not recommended due to legal stuff.
- Use a third-party service/repository of APKs — e.g. this article suggest this one, but the issue here is that you may be downloading modified or infected programs/files. Probably should be considered a last resort.
- Use a third-party extension — e.g. this one that pretends to be a device and downloads (not a good idea if you like legal stuff, plus google tracks your every move (mainly when signed in) so may be found out pretty quick. Dead as out of date on both browser and likely android support. It isn’t recommend to install extensions not in browser’s extension store anyway!
- Install it Now we get to the more fun bit of trying it out. Go to the Apps thing in chrome (or type chrome://apps in the URL bar) and launch Arc Welder. Then choose the directory the APK is in and then the APK, then choose ‘Launch App’ in the window. If the window shows the app icon as one that looks like this:
the app probably won’t work so their may not be much point in continuing. This seemed to happen alot with apps for Android 4.4+. - Use it I managed to get QuickOffice to run and mostly work under the extension, though I couldn’t save any documents as it was not happy about choosing the place to save the file (showing a folder selection box, not a file selection box for saving 😛 ) After you press ‘Launch App’, the extension automatically adds a entry to the apps page on Chrome — this you can make into a standalone application launcher to launch the app directly from your app menu/dash/launcher — this is possibly the best feature of this extension as integrates with the desktop and you don’t need to launch a emulator etc first. Overall this is brilliant, considering this probably is still in development and not designed for this it works quite well.
Alternatively you can use a emulator as suggested in other answers — I did have some success using Genymotion (there were some handy instructions here, but this answer may help). Android Emulator can be got as part of the Android Studio SDK, however since Android Nougat apps should be signed.
How to Run Android Apps on Ubuntu Linux with Anbox
For a long time people have been trying to get Android apps running on Linux. After all, it makes a whole lot of sense. Android does use the Linux kernel. So why has it been so hard then?
Aside from the Linux kernel, Linux and Android are radically different systems. Linux uses the GNU user environment, while Android has its own entirely different one that’s heavily reliant on Java. Android also relies on many Google-specific tools like those that run the Play store. Of course, none of those are available for or run on Linux.
Anbox aims to bridge the gap by providing a compatibility layer between Android apps and Linux. It uses the host system’s Linux kernel but creates its own Android userspace. You can think of it as being sort of like Wine (Windows compatibility layer).
It’s important to keep in mind that Anbox is in early Alpha. Don’t expect perfection right now. The purpose of this is to experiment and test out features and apps. Things will break. Over time, the project will mature, and you’ll probably see some improvement in the coming months.
Install Anbox
If you’re running Ubuntu, you should already have Snap installed. Anbox is packaged and distributed as a Snap package. Use it to install Anbox.
snap install --edge --devmode anbox
Install the Anbox Modules
You’re going to need a couple of specialized kernel modules before Anbox will work properly. They’re available from a PPA, so enable it on your system and install them.
sudo add-apt-repository -y ppa:morphis/anbox-support sudo apt update sudo apt install -y anbox-modules-dkms
When the install completes, you may want to restart Ubuntu to make sure that it loads the modules.
Running Anbox
Launching Anbox is a little strange. Right now the launcher itself doesn’t load everything that you need. First, you need to open up a terminal window. In that window run the following command.
It’ll look like the command is unresponsive. It’s not. Just leave that window running in the background.
Now, launch Anbox the way you normally would through Unity or whichever desktop you’re running.
It’ll take a few seconds, but Anbox will open and show you the apps that it currently has installed. The assortment is about as bare-bones as it gets. There are only basic utilities there – no browser or Play Store.
Feel free to explore what you do have. It should all work well. You’ll immediately recognize everything as the default applications that come with Android.
Install Packages With ADB
So how do you get actual apps on there? Again, this is still very rough. You need to use the ADB (Android Debug Bridge). At least it’s easy to set up.
Open a terminal and install the necessary packages with apt .
sudo apt install android-tools-adb android-tools-fastboot
After they’re done installing, you can go to a website, like ApkMirror, to pick up some Android app packages. You can’t export them from your phone because Anbox is running as an x86 computer, not ARM. That’s an important thing to keep in mind as you’re looking for apps.
It’s also important to remember that not every app will work. Currently, there’s no way to get the Play Store or Google Play Services working in Anbox. As a result, no apps that require Play Services to work will.
Once you have an app to install, you can use adb to do it. While Anbox is running, open a terminal and type the following command. The app will be installed in Anbox.
You’ll see the app icon appear in Anbox when it’s done. Try launching it. It might work; it might not. Experiment. That’s really the point right now.
Closing Thoughts
While Anbox might not be ready for daily use, it is an interesting tool that deserves some attention and some testing. As it develops and matures, Anbox may be the best way to run Android apps in Linux, and can potentially open up a whole new world of applications to Linux users.
Nick is a freelance tech. journalist, Linux enthusiast, and a long time PC gamer.
Our latest tutorials delivered straight to your inbox