
You don’t have to send server telemetry to a hosted dashboard to get crisp, high-resolution visibility. If you want real-time CPU, RAM, disk, network, process, container, and app metrics—and you’d rather not hand them to a third party—you can self-host Netdata and keep everything on your own infrastructure.
This post focuses on the Netdata Agent: the open-source piece you run on Linux that serves an interactive web UI. You’ll get a clear sense of what it’s great at, where it falls short, and how to deploy it on a VPS with HTTPS and sensible access controls. We’ll also cover what’s worth backing up and a safe update routine that won’t surprise you at 2 a.m.
What Netdata Agent is (and what “Cloud” adds)
Netdata Agent is what you install on the server you want to monitor. It samples metrics at short intervals and serves dashboards locally over HTTP. The interface is quick, and the charts are built for real troubleshooting—you can jump from “load is high” to “this process is burning CPU” in a minute.
Netdata also offers a hosted layer (Netdata Cloud) that brings multiple nodes into one view and adds centralized alerting and management. For some teams, that convenience is worth it. If you run privacy-sensitive workloads—or you simply don’t want operational data leaving the box—that trade is usually a non-starter.
License note: Netdata Agent is open source. Netdata Cloud is a hosted service. Some enterprise features and managed experiences can be commercial. Always confirm the exact terms in the upstream documentation for your planned use.
Who should self-host Netdata
Netdata is a strong fit when you run one or more Linux servers and you need immediate feedback during incidents, deploys, or performance tuning. Common use cases:
- Website operators debugging slow WordPress/PHP or Nginx/Apache responses.
- App owners running Node.js, Python, or background workers who need per-process behavior.
- VPS admins tracking noisy neighbors, iowait spikes, memory pressure, swap storms, and saturation.
- Dedicated server owners watching NVMe throughput, interrupt load, and network drops under traffic.
If you mainly need SLA-style uptime checks (not deep metrics), pair Netdata with a lightweight checker. HostMyCode already covers that workflow in Run Uptime Kuma With Docker Compose on a VPS.
Netdata Agent vs hosted monitoring dashboards (quick comparison)
Hosted monitoring products are convenient. The friction usually shows up around data custody, cost at scale, and how much local control you keep. Here’s the practical trade-off:
- Data locality: with Netdata Agent, metrics stay on the server unless you forward them.
- Latency: local charts render quickly, even during partial network incidents.
- Cost curve: one VPS can monitor itself with no per-host SaaS pricing.
- Central view: hosted platforms win for multi-node aggregation without DIY.
A common pattern in 2026 is “local-first metrics” on each node (Netdata Agent), plus a minimal centralized layer for alerts and uptime. Debugging stays fast, and you control what leaves the server.
What you’ll run it on: VPS sizing and prerequisites
Netdata is efficient, but it still does real work: sampling, short-term storage, and chart rendering. Treat it like any other always-on service and size accordingly.
- Minimum for a small VPS: 1 vCPU, 1 GB RAM, 15–20 GB disk (works for low traffic sites).
- Comfortable baseline: 2 vCPU, 2 GB RAM, 30+ GB disk (most production VPS workloads).
- Busy nodes: 4 vCPU, 4–8 GB RAM (database-heavy, high concurrency, or lots of containers).
Its footprint depends on enabled collectors and retention settings. On a tight 1 GB VPS, keep the machine tidy, disable what you don’t need, and watch disk growth.
If you want predictable CPU and NVMe performance for monitoring + your application, start with a HostMyCode VPS. If you’d rather not spend weekends patching and tuning, managed VPS hosting is the safer fit for production.
Deploy Netdata Agent on a VPS (Docker Compose)
Running Netdata in a container is a clean option if you already use Docker for your apps. You still get host metrics by mounting the right paths and granting the container access to system resources.
Assumptions: Ubuntu or Debian VPS, Docker + Docker Compose installed, and a DNS name like netdata.example.com.
1) Create a directory for Netdata
sudo mkdir -p /opt/netdata
cd /opt/netdata
2) Docker Compose file
Create /opt/netdata/docker-compose.yml:
services:
netdata:
image: netdata/netdata:stable
container_name: netdata
pid: host
network_mode: host
restart: unless-stopped
cap_add:
- SYS_PTRACE
- SYS_ADMIN
security_opt:
- apparmor=unconfined
volumes:
- netdataconfig:/etc/netdata
- netdatalib:/var/lib/netdata
- netdatacache:/var/cache/netdata
- /etc/passwd:/host/etc/passwd:ro
- /etc/group:/host/etc/group:ro
- /proc:/host/proc:ro
- /sys:/host/sys:ro
- /etc/os-release:/host/etc/os-release:ro
- /var/run/docker.sock:/var/run/docker.sock:ro
volumes:
netdataconfig:
netdatalib:
netdatacache:
This uses network_mode: host so Netdata can bind directly to the host and see what it needs. You can run it in bridge mode with explicit port mappings, but host mode typically avoids a long list of “why can’t it see X?” surprises.
3) Start the service
sudo docker compose up -d
sudo docker ps --format 'table {{.Names}}\t{{.Status}}\t{{.Ports}}'
By default, Netdata listens on port 19999. Don’t expose that port to the public internet. Put it behind a reverse proxy with HTTPS and access restrictions.
Reverse proxy with HTTPS (Nginx) and basic access control
Netdata’s UI is useful because it’s detailed—and that detail is exactly why you shouldn’t leave it open. Treat it like an internal admin tool.
The approach below keeps Netdata on the host, terminates TLS at Nginx, and limits access. You can restrict by IP, by HTTP basic auth, or both.
1) Install Nginx and Certbot
sudo apt update
sudo apt install -y nginx certbot python3-certbot-nginx
2) Create an Nginx site for Netdata
Create /etc/nginx/sites-available/netdata:
server {
listen 80;
server_name netdata.example.com;
location / {
proxy_pass http://127.0.0.1:19999;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
# Keep the UI snappy over slow links
proxy_read_timeout 60s;
}
# Optional: simple IP allowlist (example)
# allow 203.0.113.10;
# allow 198.51.100.0/24;
# deny all;
}
Enable the site and reload:
sudo ln -s /etc/nginx/sites-available/netdata /etc/nginx/sites-enabled/netdata
sudo nginx -t
sudo systemctl reload nginx
3) Add HTTPS with Let’s Encrypt
sudo certbot --nginx -d netdata.example.com
4) Add HTTP Basic Auth (recommended)
IP allowlists work until you travel, switch networks, or your ISP changes addresses. Basic auth is simple, reliable, and easy to manage with a password manager.
sudo apt install -y apache2-utils
sudo htpasswd -c /etc/nginx/.htpasswd netdataadmin
Then edit the Nginx location / block:
location / {
auth_basic "Netdata";
auth_basic_user_file /etc/nginx/.htpasswd;
proxy_pass http://127.0.0.1:19999;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_read_timeout 60s;
}
Reload Nginx:
sudo nginx -t
sudo systemctl reload nginx
If you want something stronger than basic auth, put an identity-aware proxy (OAuth2/OIDC) in front. The hardening principles stay the same; only the “front door” changes.
Lock down the firewall: expose only what’s needed
Don’t bet on “nobody will find it.” If your VPS uses UFW:
sudo ufw allow OpenSSH
sudo ufw allow 80/tcp
sudo ufw allow 443/tcp
sudo ufw deny 19999/tcp
sudo ufw enable
sudo ufw status verbose
Also harden SSH. If you’re still using password logins, switch to keys first—your monitoring box is still a server. HostMyCode’s guide is tight and practical: Set Up SSH Keys And Disable Password Login On VPS.
Backups: what to save (and what you can ignore)
Netdata usually isn’t your long-term system of record. For most setups, it’s a diagnostic lens: you use it to explain what’s happening right now, and what changed recently.
Back up what helps you rebuild quickly and preserves your intent:
- Configuration (collectors, alarms, plugins): inside
/etc/netdata. - Custom health alarms you created or tuned.
- Reverse proxy config:
/etc/nginx/sites-available/netdata, TLS cert renewal state, and auth file.
If you deployed with Docker named volumes, back up the config volume. One straightforward approach is a one-shot container that tars the volume content to a safe location.
Example: export Netdata config volume to a backup directory
sudo mkdir -p /var/backups/netdata
sudo docker run --rm \
-v netdata_netdataconfig:/data:ro \
-v /var/backups/netdata:/backup \
alpine sh -c "cd /data && tar -czf /backup/netdataconfig-$(date +%F).tar.gz ."
Retention tip: keep 7–14 daily copies, plus a few weekly copies. If disk is tight, prune hard.
Want a reusable “don’t lose your Docker app data” pattern? The mechanics are similar to what you’d use for other services you host on a VPS, like the ones in Run Open WebUI With Persistent Storage on a VPS.
Safe updates: avoid surprise breaking changes
Monitoring updates should be boring. A dependable routine is: review, pull, restart, verify.
- Pin to stable (as in the Compose file) unless you have a reason to run nightly builds.
- Update during a calm window, not mid-incident.
- Restart and validate that charts populate and collectors stay healthy.
Update commands (Docker Compose)
cd /opt/netdata
sudo docker compose pull
sudo docker compose up -d
sudo docker logs --since=5m netdata | tail -n 80
If you like automated image refreshes, be careful with anything that updates without your approval. At minimum, alert on container restarts. HostMyCode’s walkthrough on controlled Docker updates is useful context: Docker Compose Auto-Updates With Watchtower on a VPS.
Operational checklist: keep Netdata helpful, not noisy
Dashboards drift into background noise when nobody tunes them. A few simple checks keep Netdata useful:
- Confirm time sync (chrony/systemd-timesyncd). Bad time ruins “what changed?” analysis.
- Watch disk usage on small VPS plans. A full root filesystem breaks everything.
- Don’t over-collect on low-resource nodes. Disable collectors you don’t use.
- Protect access. HTTPS + auth + firewall is the baseline.
If your VPS runs out of space, fix that first before blaming the app. This guide helps you find the real culprits safely: Disk Full on VPS: Find Large Files and Free Space Safely.
Where Netdata shines for website and app troubleshooting
Netdata earns its keep in the “something feels off” category. A few scenarios you’ll probably recognize:
- WordPress feels slow after a plugin update: check CPU saturation, PHP-FPM process churn, and database I/O spikes.
- Random 504s on Nginx: correlate upstream response time with CPU steal, memory pressure, and iowait.
- App deploy caused errors: watch container restarts and per-process memory growth (a slow leak shows up quickly).
If you’re already fighting 504s, fix the web stack and use Netdata to confirm the improvement. This is a solid companion read: Fix WordPress 504 Gateway Timeout on Nginx VPS.
Summary: a private, real-time metrics setup you control
If you want high-resolution server metrics without shipping operational data to a hosted dashboard, self-host Netdata as a local-first monitoring layer. Put it behind HTTPS, require authentication, keep port 19999 off the public internet, and back up what matters (config and proxy settings).
For production workloads, a VPS with consistent CPU and NVMe storage makes Netdata noticeably smoother under load. If you’re building a monitoring baseline for multiple sites, start with a HostMyCode VPS and scale up as you add nodes. If you’d rather have someone handle routine hardening and maintenance, managed VPS hosting is a clean option.
Netdata is easiest to live with when the server underneath it has predictable CPU, fast storage, and stable networking. HostMyCode’s VPS hosting gives you a solid baseline, and managed VPS hosting is there if you want help keeping the stack patched and stable.
FAQ
Should I expose Netdata directly to the internet?
No. Keep port 19999 closed publicly. Use a reverse proxy with HTTPS and require authentication (and/or an IP allowlist).
Is Docker required to run Netdata Agent?
No. Netdata can be installed directly on the OS as well. Docker Compose is a tidy option when you already run containerized services and want easy updates and rollback.
What should I back up for Netdata?
Back up configuration (/etc/netdata), any custom alarms, and your reverse proxy configuration. Most people don’t need to preserve historical metrics long-term.
Can Netdata replace uptime monitoring?
Not really. Netdata excels at metrics and live troubleshooting. For “is it up?” checks and notifications, use a dedicated uptime tool (often alongside Netdata).
Will Netdata slow down a small VPS?
On very small plans (1 vCPU / 1 GB RAM), it can be noticeable if you enable many collectors. Start with defaults, avoid exposing it publicly, and upgrade the VPS if you’re consistently CPU-bound.