Learn how to install and configure Uptime Kuma on Ubuntu 24.04 to monitor your website uptime and server health.
Staying online is critical. That’s why having an uptime monitoring solution like Uptime Kuma is a game-changer for developers, small businesses, and self-hosted service owners. In this guide, we’ll show how to install and set up Uptime Kuma on Ubuntu 24.04 to keep track of our websites, servers, and APIs — all with a beautiful UI and zero subscription cost.
What is Uptime Kuma?
Uptime Kuma is an open-source self-hosted monitoring tool, often called the “open-source alternative to Uptime Robot.” It offers real-time monitoring of HTTP(s), TCP, ping, and more. With it, we can:
- Monitor website uptime and response time
- Receive alerts via email, Telegram, Discord, and more
- Track history with clean graphs
- Host everything ourselves with full control
Prerequisites
Before starting, make sure Ubuntu server is ready.
- A Ubuntu 24.04 installed dedicated server or KVM VPS.
- A root user or normal user with administrative privileges.
- A domain name pointing to server IP.
How to Install and Set Up Uptime Kuma on Ubuntu 24.04 for Self-Hosted Website Monitoring (Step-by-Step Guide)
Step 1: Update the System
We always start with a system update to make sure our packages are current.
sudo apt update && sudo apt upgrade -y
Step 2: Install Required Dependencies
Install Git, curl, and build tools needed for Node.js:
sudo apt install git curl build-essential -y
Step 3: Install Node.js (LTS)
Uptime Kuma runs on Node.js. We'll install the latest LTS version using NodeSource:
curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
sudo apt install nodejs -y
Verify the installation:
node -v
npm -v
Step 4: Clone the Uptime Kuma Repository
Next, we clone the official repo to our server:
git clone https://github.com/louislam/uptime-kuma.git
cd uptime-kuma
Step 5: Install Dependencies
From the project directory, install all necessary packages:
npm run setup
This will take a few minutes. It installs the backend and frontend dependencies automatically.
Step 6: Start Uptime Kuma
Once installed, we can start Uptime Kuma using:
node server/server.js
- This starts the service at http://localhost:3001
- http://<your-server-ip>:3001
Step 7: Access the Dashboard
Open your browser and go to the server IP on port 3001.
- Set up the admin user and password
- Start adding monitors (websites, services, APIs)
We can monitor:
- HTTP/HTTPS
- TCP ports (like SSH, FTP)
- Ping
- DNS
- Push notifications from scripts
- Certificate expiry
Step 8: (Optional) Run Uptime Kuma as a Systemd Service
To keep Uptime Kuma running in the background and restart on boot, we create a systemd service:
sudo nano /etc/systemd/system/uptime-kuma.service
Paste the following:
[Unit]
Description=Uptime Kuma Monitoring Tool
After=network.target
[Service]
Type=simple
User=ubuntu
WorkingDirectory=/home/ubuntu/uptime-kuma
ExecStart=/usr/bin/node server/server.js
Restart=always
[Install]
WantedBy=multi-user.target
Update User and WorkingDirectory paths as per your server setup.
Save and enable the service:
sudo systemctl daemon-reexec
sudo systemctl enable uptime-kuma
sudo systemctl start uptime-kuma
Check status:
sudo systemctl status uptime-kuma
Step 9: Configure Firewall
We need to add HTTP and HTTPS ports in the firewall.
ufw allow 80/tcp
ufw allow 443/tcp
ufw reload
Step 10: Secure It with Nginx and HTTPS (Optional but Recommended)
If we own a domain and want HTTPS:
Install Nginx:
sudo apt install nginx -y
Create a reverse proxy config:
sudo nano /etc/nginx/sites-available/uptime-kuma
Add:
server {
listen 80;
server_name monitor.example.com;
location / {
proxy_pass http://localhost:3001;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}
Enable the config:
sudo ln -s /etc/nginx/sites-available/uptime-kuma /etc/nginx/sites-enabled/
sudo nginx -t
sudo systemctl reload nginx
Enable HTTPS with Certbot:
sudo apt install certbot python3-certbot-nginx -y
sudo certbot --nginx -d monitor.example.com
Done. Uptime Kuma is now running securely on HTTPS.
Final Words
That’s it — we’ve successfully set up Uptime Kuma on Ubuntu to monitor our websites, APIs, and services with full control. This open-source tool is lightweight, fast, and beautiful. Plus, we don’t rely on third-party platforms for uptime monitoring anymore.
By using a tool like Uptime Kuma, we take back control, improve uptime awareness, and keep our users happy.
Check out our low cost dedicated server.