---
title: Installing a self-hosted UniFi Network Server on Debian 11
canonical: https://0110.be/posts/Installing_a_self-hosted_UniFi_Network_Server_on_Debian_11
markdown_url: https://0110.be/posts/Installing_a_self-hosted_UniFi_Network_Server_on_Debian_11.md
id: 524
published_at: '2023-09-08T00:00:00Z'
updated_at: '2023-09-08T12:28:25Z'
author: Joren
tags:
- name: UGent
  markdown_url: https://0110.be/tags/UGent.md
---

# Installing a self-hosted UniFi Network Server on Debian 11

<div style="float:right; width:25%;margin-left:10px;margin-bottom:10px">
<center>
<img src="https://0110.be/files/attachments/524/UniFi-management.jpg" alt="UniFi manager" style="width:90%;box-shadow: 0 3px 5px rgba(0, 0, 0, 0.4);" ><br><small>Fig: UniFi manager.</small>

</center>
</div>
I have been using a couple of UniFi devices in my home network for a couple of years. These devices proved to be reliable and full-featured, especially considering the relatively low price point. To manage UniFi devices a self-hosted instance of the UniFi network server is practical, especially when you already have a home server.

Unfortunately, the [official installation instructions for UniFi](https://help.ui.com/hc/en-us/articles/360012282453-Self-Hosting-a-UniFi-Network-Server) miss a crucial step for installation on Debian 11. The network manager is not compatible with newer versions of [mongodb](https://www.mongodb.com/). To install a version of mongodb compatible with UniFi on Debian 11, use the following commands:

    wget -qO - https://www.mongodb.org/static/pgp/server-3.6.asc | sudo apt-key add -
    echo "deb http://repo.mongodb.org/apt/debian stretch/mongodb-org/3.6 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.6.list
    sudo apt-get install mongodb-org=3.6.23
    sudo apt-get install mongodb-org-server=3.6.23

