Self-Hosting a UniFi Network Server as a Windows Service (Advanced)

Running a UniFi Network Server on Windows operating systems can be done using one of two methods:

  1. From the launcher: UniFi Network runs in the foreground (default method).
  2. As a Windows service: UniFi Network runs in the background (advanced, continue below).
Please note that this method only applies to a UniFi Network Server installed on Windows Desktop (Windows 10 / 11) and not Windows Server versions.

New Set Up

1. Download the UniFi Network Server (Windows) from the Downloads page and run the installer. We recommend installing the latest version of the UniFi Network Server for the best experience.

2. Download Java for Windows with the following specifications. The latest version of the UniFi Network Server (7.5) requires Java 17.

  • Package Type: JRE
  • Architecture: x64
  • Version: 17 (or applicable version)
  • File Type: .msi

Note: Install only one version of Java.

3. Run the Java installer and set the Set JAVA_HOME variable to "Will be installed on local hard drive" as seen below.

java.png

Note: If you are experiencing issues with the Java installer or the JAVA_HOME variable, then remove the other/older Java versions that are present on the system.

5. Enable TCP Port 8080TCP Port 8843UDP Port 10001, and UDP Port 3478 on any local firewall (including Windows Defender) or antivirus software. See our Required Ports Reference to learn more.

6. Open a Windows Command Prompt (CMD) window as an admin

7. Change the directory to the location of UniFi installation.

cd "%UserProfile%\Ubiquiti UniFi\"

8. Once in the root of the UniFi folder, run the following command to install the service:

java -jar lib\ace.jar installsvc

9. Wait for the installation to complete, indicated by the "Complete Installation" log message.

10. Start the UniFi Network Server service with the command below: 

java -jar lib\ace.jar startsvc

11. Open a browser and navigate to the server's IP address or https://localhost:8443 to configure the UniFi Network Server.

Upgrade an Existing Set Up

1. Download a backup of the UniFi Network Server and close it. 

2. Open a Windows Command Prompt (CMD) window as an admin.

3. Change the directory to the location of UniFi installation.

cd "%UserProfile%\Ubiquiti UniFi\"

4. Once in the root of the UniFi folder, issue the following to uninstall the service:

java -jar lib\ace.jar uninstallsvc

5. Wait for the service uninstall process to complete. 

6. Follow steps 1-11 from the New Set Up section above to install an upgraded version of the UniFi Network Server as a service.

Was this article helpful?
750 out of 1322 found this helpful