LuCI Bandix
LuCI Bandix (luci-app-bandix) is the web front end for Bandix, an eBPF-based network traffic monitor for OpenWrt routers. It adds a Network → Bandix menu to the LuCI web interface where you can watch per-device upload and download speeds in real time, browse historical traffic, set WAN speed limits and data quotas per device, inspect each device's TCP/UDP connections, and analyze the DNS queries made on your network.
This documentation covers the LuCI application in depth: how it is installed, every setting it writes, what each page shows and how it behaves, the luci.bandix RPC interface it uses to talk to the backend, and the quirks visible in its source code.
Note: LuCI Bandix is only the user interface. All monitoring, storage and enforcement is done by the separate openwrt-bandix backend service (package name
bandix), which must be installed first. See Installation.
What Problem It Solves
Stock OpenWrt tells you how much traffic crosses an interface, but not which device on your LAN is using it, how fast, or when. Bandix attaches small eBPF programs to the traffic-control (TC) hooks of your LAN interface, counts bytes per MAC address in the kernel, and exposes the results through a local HTTP API. LuCI Bandix turns that API into a dashboard and a set of controls that fit into the regular OpenWrt admin interface, so you never need a separate web server, port forward or app.
Typical uses:
- Finding out which device is saturating the internet connection right now.
- Reviewing how much a device downloaded today, this week or last month.
- Capping a device's WAN speed during certain hours (for example, a games console on school nights).
- Giving a device a daily or monthly data allowance that blocks its WAN traffic once used up.
- Checking which remote hosts and countries a device is connected to.
- Seeing which domains each device resolves, and how fast your DNS server answers.
Key Features
| Feature | What you get | Page |
|---|---|---|
| Real-time device list | Per-device LAN and WAN upload/download speed and totals, online status, Wi-Fi band and uplink interface | Status Page |
| Realtime traffic trends | A live chart (1 sample per second) of total, LAN or WAN rates, for all devices or one device | Status Page |
| Traffic statistics | Device usage ranking and an hourly/daily traffic timeline for any date range up to a year | Status Page |
| Hostname bindings and device cleanup | Rename devices, delete one or many devices and their history | Devices and Hostnames |
| WAN rate limiting | Time-of-day schedule rules per device, plus a global default limit with an exemption whitelist | Rate Limits |
| Traffic quotas | Minute, hourly, daily, weekly, monthly and lifetime WAN quotas, combined or separate per direction | Traffic Quotas |
| Connection monitor | TCP/UDP connection counts per device and a searchable, paginated list of each device's flows | Connection Monitor |
| IP location lookup | Country, city and ASN information for connection endpoints from a GeoLite2 .mmdb database |
IP Location Database |
| DNS monitor | Query and response log with filters, response-time statistics and top domains, devices and servers | DNS Monitor |
| Built-in updater | Checks GitHub releases for both packages and installs the matching .ipk or .apk |
Updates and Maintenance |
| Push integrations | Optional HTTP endpoints that receive traffic data and device online/offline events | Configuration |
Other properties worth knowing:
- IPv4 and IPv6 addresses are shown for each device.
- Hostnames are taken from the backend's device data (DHCP/DNS and static leases), and can be overridden per MAC address.
- Persistence is optional. Realtime data lives only in memory. Long-term history and DNS records are written to disk only when you enable persistence.
- Translations ship for Simplified and Traditional Chinese, Japanese, French, Russian, Polish and Spanish.
- Theme-aware styling for the OpenWrt 2020, Bootstrap, Material, Argon, Aurora and Kucat LuCI themes, including their dark modes.
A Short Example
After installing both packages, open Network → Bandix → Settings, pick your LAN interface (usually br-lan), tick Enable Traffic Monitoring, and click Save & Apply. The same configuration from an SSH shell looks like this:
uci set bandix.general.iface='br-lan'
uci set bandix.traffic.enabled='1'
uci commit bandix
/etc/init.d/bandix restart
Then open Network → Bandix → Status. Within a second or two the device list fills with every LAN client the backend has seen, each with live download and upload speeds and running totals.
How It Works
LuCI Bandix is made of three layers that run entirely on the router:
- JavaScript views in the browser (
Status,Connections,DNS,Settings) poll for data every second and draw tables and canvas charts. - An rpcd plugin, the shell script
/usr/libexec/rpcd/luci.bandix, exposes theluci.bandixubus object. Each RPC method makes acurlrequest to the backend and returns its JSON. - The Bandix backend listens on
127.0.0.1:8686by default, reads the counters collected by its eBPF programs, keeps realtime and long-term statistics, and enforces rate limits and quotas.
The Architecture page describes the data flow, polling intervals and the eBPF design in detail.
When to Use It, and When Not
LuCI Bandix is designed for home and small-office networks with a single LAN segment. It works best when:
- the router runs Linux kernel 6.x or newer (OpenWrt 24.10 or newer is recommended),
- all clients sit on one LAN bridge or interface that you can select in the settings,
- hardware flow offloading and Turbo ACC are disabled, so packets actually pass through the kernel where the eBPF programs can see them.
It is not a good fit for:
- complex topologies such as several VLANs or many separate LAN interfaces (the project points to its sibling, LuCI Bandix Plus, for multi-interface setups),
- enterprise deployments that need per-user accounting, auditing or long retention,
- routers that rely on hardware NAT offload for throughput, because offloaded traffic is invisible to Bandix.
Note: LAN-to-LAN traffic between two devices on the same switch chip (for example a PC copying files to a NAS) may never reach the router's CPU and therefore may not be counted. This is a hardware limitation, not a bug.
Project Status
The project is actively developed. The version in this repository is 0.12.12 (package release 5). luci-app-bandix and the backend are versioned together: a 0.12.x front end requires a 0.12.x backend. The project is licensed under the Apache License 2.0. Release notes are published on the GitHub releases page.
Where to Go Next
- Installation: requirements, package installation and verification.
- Quick Start: from a fresh install to a working dashboard and a first rate limit.
- Configuration: every UCI option with its default.
- Status Page: the device list, charts and statistics explained.
- Troubleshooting: empty device lists, missing traffic, failed updates and more.
- RPC Methods: the
luci.bandixubus API for scripting.