WLED TUI is a multi-device terminal UI for Linux, written in Bash, that controls WLED lights via the WLED JSON HTTP API.
WLED TUI provides a full-screen Bash TUI (tput/stty) for discovering and managing multiple WLED instances, switching between devices, and adjusting common WLED state such as power, brightness, presets, effects, palettes, segments, colors, and more.
- Multi-device support with quick switching and a per-device online/offline indicator.
- Bonjour/mDNS discovery using Avahi (
avahi-browse), probing_wled._tcpfirst and falling back to_http._tcpwith a/json/infoprobe. - Manual device add, edit, and remove (host:port).
- Device cache stored in
~/.config/wledtui/devices.json(respectsXDG_CONFIG_HOME). - Status tab: power toggle and brightness adjustments.
- Presets tab: list and apply presets from
/presets.json(fallback to/json/presets). - Effects tab: list/apply effects; adjust speed or intensity per segment.
- Palettes tab: list/apply palettes per segment.
- Segments tab: toggle segment on/off, edit primary RGB color, and apply changes to all segments.
- Advanced tab: adjust transition time, toggle nightlight, toggle live mode, and reboot.
- Help overlay and footer key legend.
- Polling with backoff: selected device refreshes about every 2s, all devices about every 8s, with offline retry backoff up to 30s.
- Debug logging via
WLEDTUI_DEBUG=1to~/.cache/wledtui/debug.log(respectsXDG_CACHE_HOME). - Optional smoke test mode (
./wledtui --smoke HOST:PORT).
On startup, WLED TUI performs an mDNS/Bonjour scan using Avahi (avahi-browse) before drawing the UI, so the device list is populated immediately when the interface renders. Discovery requires:
avahi-daemonrunning and reachable on the host.avahi-browseinstalled (typically provided byavahi-utilsoravahi-tools).- mDNS/Bonjour traffic allowed (UDP 5353); ensure your firewall and network allow multicast and that WLED devices are on the same L2/VLAN or an mDNS reflector is configured.
If no _wled._tcp services are found, WLED TUI falls back to _http._tcp and probes each candidate with /json/info to confirm it is a WLED device.
- Bash 5+
curljqavahi-browse+avahi-daemon(required for discovery)- A terminal that supports standard ANSI escape sequences (works over SSH)
Keep it short—install the dependencies with your distro’s package manager:
# Debian/Ubuntu
sudo apt-get install -y bash curl jq avahi-utils
# Fedora
sudo dnf install -y bash curl jq avahi-tools
# Arch
sudo pacman -S bash curl jq avahichmod +x ./wledtui
./wledtuiUse the same key labels as the footer legend:
| Key | Action |
|---|---|
| (q) | Quit |
| (tab) | Next tab |
| (shift+tab) | Previous tab |
| (↑/↓) | Move selection (devices or list items) |
| (←/→) | Adjust values (brightness, speed/intensity, RGB channel, transition) |
| (enter) | Apply/toggle (power, preset, effect, palette, segment, nightlight) |
| (r) | Refresh selected device |
| (s) | Scan (Bonjour) |
| (a) | Add device (host:port) |
| (d) | Delete device |
| (e) | Edit device (host:port) |
| ([ / ]) | Previous/next device |
| (i) | Toggle effect control (speed/intensity) |
| (c) | Cycle RGB channel in segment color editor |
| (g) | Toggle apply-to-all segments |
| (l) | Toggle live mode |
| (b) | Reboot device |
| (?) | Toggle help overlay |
~/.config/wledtui/devices.json— cached devices (usesXDG_CONFIG_HOMEif set).~/.cache/wledtui/debug.log— debug logs whenWLEDTUI_DEBUG=1(usesXDG_CACHE_HOMEif set).
- Discovery finds nothing:
- Confirm
avahi-daemonis running. - Ensure
avahi-browseis installed and in$PATH. - Check firewall rules for UDP 5353 multicast.
- If devices are on another VLAN/subnet, enable an mDNS reflector or move devices to the same L2 segment.
- Confirm
- Device shows offline / timeouts:
- Verify the device IP/port in
devices.jsonor re-add it. - WLED TUI uses short HTTP timeouts; intermittent Wi-Fi can cause temporary offline status and exponential backoff.
- Verify the device IP/port in
- Keys not working in some terminals:
- Some terminals remap or delay escape sequences; try a different terminal or SSH client if arrow keys or Shift-Tab do not register correctly.
- Discovery relies on Avahi; without it, devices must be added manually.
- Only the WLED JSON HTTP API is supported (
/json/state,/json/info,/json/effects,/json/palettes,/presets.json//json/presets).