info_i_25x25.png See important information about Ubiquiti Devices and KRACK Vulnerability in this article. We will update this document as more information becomes available.

UniFi - How to Install & Update via APT on Debian or Ubuntu

thumbs_up_i_25x25.png  Was this useful? Help us identify your favorite articles by clicking on the thumbs up at the bottom of the page. And if you think this article is not useful, please let us know why by clicking on the feedback link below!


This article provides a list of source files you'll need to create, or lines you can use in an existing sources.list file, if you wish to be able to install and update the UniFi controller on your Debian or Ubuntu system via APT. That is the most common method for package updates and installs for these OS. The repo structure should be permanent, but if there are any changes they will be pointed out in the release posts.

Table of Contents

  1. UniFi Controller APT Steps
  2. Troubleshooting
  3. User Notes & Tips
  4. Related Articles

UniFi Controller APT Steps

Back to Top

1. Add /etc/apt/sources.list.d/100-ubnt.list (or edit /etc/apt/sources.list). The stable, old stable and testing sources are considered floating, which means they can change at any time. Typically there will be a post on the community announcing this. 

If you wish to stay with a specific release branch, then you must specify the appropriate code name on the source line.

We currently use the following code names unifi3/unifi4/unifi5 but they are going to be obsoleted. The following is an updated sample of a sources file. Note, the source line can contain either a suite name or a code name, although we recommend using the suite name (e.g. stable, testing, etc.). 

info_i_25x25.png Note: When following the instructions below, note that using on a browser will result in a 403 Forbidden page. This is because we do not allow direct listing/access to this link. The URL is only meant to be used when working on CLI to run the commands below.

For Debian/Ubuntu, add the repo, which would be one of these depending on the specific release branch wanted:

deb testing ubiquiti
deb oldstable ubiquiti
deb stable ubiquiti

The table below shows the suite name with its corresponding code name:

 Suite Name Code Name
oldstable unifi-5.4
stable unifi-5.5
testing unifi-5.6
cloudkey-oldstable uck-5.4
cloudkey-stable uck-5.5
cloudkey-testing uck-5.6

2. Add the GPG Keys. 


  • For Ubiquiti:
sudo apt-key adv --keyserver --recv 06E85760C0A52C50
  • Or over HTTP use:

3. Update. Retrieve the latest package information:

sudo apt-get update

4. Install and upgrade the UniFi controller:

sudo apt-get install unifi

5. (Optional) This step may not be required, depending on the Linux distro you have. If your distro does not come with MongoDB, and it's not available in their repo, then please see the MongoDB installation guide. You can find the latest installation guide for Ubuntu HERE, and Debian HERE. We recommend at least MongoDB 2.6.10. Some users have changed the backend to use MongoDB 3 successfully too.


Back to Top

Find the log files here:

User Notes & Tips

Back to Top

These notes have been added thanks to user collaboration. Have anything to contribute? Click on the Give Feedback button below!

  • If it's taking too long to access the controller after a restart, and you need to generate enough entropy on a headless VM to start up SSL, this Community post might help: Ubuntu 14.04 x64 Unifi 4.6.6 very slow start up.
  • At the moment Ubiquiti does not support arm64, hence it is not available via the repo. A download and manual installation will be necessary. The bundled snappy-java package in versions 5.5.x and previous, do not support arm64. In v5.6.1 Unstable (might be reverted for 5.6.2) that changed to an updated snappy-java package. That being said, the following script can be run after install to update the bundled version, which should help it run:
rm /usr/lib/unifi/lib/snappy-java-1.0.5.jar
wget -O /usr/lib/unifi/lib
  • If the system continues to report issues with snappy-java, you should rename the new jar file or link it to whatever name the original jar file that came with the UniFi distro had. For example:
cd /usr/lib/unifi/lib
rm snappy-java-1.0.5.jar
ln -s snappy-java-1.1.4-M3.jar snappy-java-1.0.5.jar
info_i_25x25.png Note: The distributed jar will change as the UniFi firmware versions progress, so use the example above as a guide, but adjust file names accordingly. For example, as of 5.5.20, the distributed jar is snappy-java-, not snappy-java-1.0.5.jar. Linking to snappy-java-1.0.5.jar would not work in the example above, but linking to snappy-java- would.

Related Articles

Back to Top

UniFi - Recommended Minimum System Requirements