Quick Start
Prerequisites
Before getting started, ensure you have the following:
- Node.js: version 20.x (recommended) or 14+.
- UniFi Credentials: You will need a UniFi API Key and your UniFi Network Application URL.
- Note: The URL should typically follow the format:
https://<your-host>/proxy/network/integration/v1.
- Note: The URL should typically follow the format:
Local Installation
To run the dashboard directly on your machine, follow these steps:
-
Clone the repository and navigate to the project directory:
git clone https://github.com/suddenelfilio/unifi-dashboard.git cd unifi-dashboard -
Install dependencies:
npm install -
Configure your environment: Copy the example configuration file and open it in your preferred editor:
cp .env.example .env -
Add your credentials to the
.envfile:UNIFI_API_KEY=your_unifi_api_key_here UNIFI_API_URL=https://your-unifi-host.com/proxy/network/integration/v1 PORT=3000 -
Start the server:
npm start
Once the server is running, visit http://localhost:3000 in your web browser.
Docker Deployment
The dashboard is provided as an optimized, non-root Alpine-based image for secure production environments.
Using Docker Run
Run the container immediately by passing your environment variables:
docker run -d \
--name unifi-dashboard \
-p 3000:3000 \
-e UNIFI_API_KEY=your_api_key \
-e UNIFI_API_URL=https://your-unifi-host.com/proxy/network/integration/v1 \
suddenelfilio/unifi-dashboard:latest
Using Docker Compose
Create a docker-compose.yml file for easier management:
version: '3.8'
services:
unifi-dashboard:
image: suddenelfilio/unifi-dashboard:latest
ports:
- "3000:3000"
environment:
- UNIFI_API_KEY=your_api_key
- UNIFI_API_URL=https://your-unifi-host.com/proxy/network/integration/v1
restart: unless-stopped
Run docker-compose up -d to start the service.
Configuration Reference
The application relies on the following environment variables. These must be set in your .env file or passed to your Docker container.
| Variable | Description | Required |
| :--- | :--- | :--- |
| UNIFI_API_KEY | Your UniFi Network Application API key. | Yes |
| UNIFI_API_URL | The base URL for your UniFi API (including the version path). | Yes |
| PORT | The port the internal BFF (Backend-for-Frontend) server listens on. Defaults to 3000. | No |
Basic Usage
- Dashboard Access: Once loaded, the dashboard automatically fetches data for all sites associated with your API key.
- Auto-Refresh: By default, the dashboard refreshes every 15 seconds. You can toggle this off or view the countdown timer in the header.
- Filtering: Use the "Site Filter" panel to show or hide specific locations. Your selection persists across browser refreshes.
- Notifications: The dashboard will play a sound and show a visual alert whenever a client connects or disconnects. Use the 🔔 icon in the header to mute these sounds.