Stage P1 and P2 of docs/important/console-backend-strangler.md, following the architecture question in discussion #496. Trust bridge (P1): the console signs a short-lived HMAC-SHA256 statement (method, path, subject, role, org, issue/expiry, nonce) with PANEL_TRUST_SECRET. Go verifies the signature, the window, the replay nonce and the endpoint, accepts it only from loopback or PANEL_TRUST_ALLOWED_HOSTS, and takes the role from the database when the account still exists - so a demoted user cannot keep an old session's role, and device/pro roles are refused outright. With no secret the bridge is off and authentication is exactly as before. Panel grouping (P2): Go now owns the writes for device groups, their members and ACL, folders, device->folder assignment and per-user device grants, and creates the tables on SQLite it previously only read. Every write is transactional, so the RustDesk sync reader never sees a half-applied ACL. The console keeps its screens and response shapes through services/panelGrouping.js. BACKEND_PANEL_GROUPING=node restores the old writer without a redeploy; a 404/501/503 falls back automatically while a 400/403 is final and never retried through the other writer. Both .env keys are appended by the updater when missing and never overwritten, so existing installs keep working untouched. Refs #496 Thanks: INSOLVE (Honorary); Marco Jakobs (@jacotec); MyNameisStitch (@MyNameisStitch); Redspin (@playerumpknow); muopc (@muopc)
BetterDesk
Self-hosted RustDesk-compatible server in Go (one binary instead of hbbs + hbbr) plus a Node.js web console.
Wiki · Privacy · Sponsors · Changelog
Honorary supporter
INSOLVE — see SPONSORS.md for everyone who backs the project.
Alpha desktop apps: Tauri MGMT / Agent clients are not for production. Use the web console and a normal RustDesk client. Details: Alpha notice.
Your data stays on your server. The project does not run vendor analytics — PRIVACY.md.
AI-assisted development: BetterDesk is created and maintained with the assistance of artificial intelligence tools.
Quick start
Linux
git clone https://github.com/UNITRONIX/BetterDesk.git
cd BetterDesk
sudo ./betterdesk.sh
Choose 1 for a new install, or sudo ./betterdesk.sh --auto.
Docker
One container with everything inside (server + relay + web console) — the recommended setup:
curl -fsSL https://raw.githubusercontent.com/UNITRONIX/BetterDesk/main/docker-compose.quick.single.yml -o docker-compose.yml
docker compose pull && docker compose up -d
docker compose exec betterdesk betterdesk-show-admin-credentials
Open http://your-server:5000 (plain HTTP, not HTTPS).
Legacy two-container layout (split images)
curl -fsSL https://raw.githubusercontent.com/UNITRONIX/BetterDesk/main/docker-compose.quick.yml -o docker-compose.yml
docker compose pull && docker compose up -d
docker compose exec console betterdesk-show-admin-credentials
The split layout is kept for existing deployments (API port 21114, single container uses 21121). New installs should use the all-in-one image above.
Windows
Run betterdesk.ps1 as Administrator — see the Installation wiki.
Documentation
| Topic | Where |
|---|---|
| Full guides | GitHub Wiki |
| Install / Docker / clients | Installation · Docker · Client setup |
| Config, TLS, updates | Configuration · TLS · Panel updates |
| Monitoring / WoL | Monitoring · Unattended & WoL |
| Help | Troubleshooting · FAQ |
| Privacy / license | PRIVACY.md · Licensing |
| Developers | docs/ · API · CDAP · Contributing |
Wiki source in-repo: docs/wiki/ (sync with scripts/sync-wiki.ps1 / .sh).
Web console preview
The BetterDesk web console defaults to the UX 3.5 interface; an opt-in UX 3.6 beta layout (grouped sidebar, list-first devices, per-topic settings) is available in Settings → General. These preview images show the UX 3.5 dark theme in English with fictional device data:
![]() |
![]() |
| Login | Dashboard |
![]() |
![]() |
| Devices | Device details |
![]() |
|
| Settings → Updates | |
See the Web Console wiki page for the full visual tour and panel capabilities.
Ports (short)
| Port | Role |
|---|---|
| 21116 TCP+UDP | Signal |
| 21117 TCP | Relay |
| 21121 | RustDesk Client API (Go; optional Node proxy) |
| 21114 | Admin REST (usually localhost) |
| 5000 | Web console |
| 21122 | CDAP (optional) |
Contributing
Diagnostics → issue → fork / PR. See docs/development/CONTRIBUTING.md.
Credits
Console redesign — UX 3.6
The UX 3.6 beta console layout is modelled on the community redesign by Linus Rath (@rathlinus) — the grouped sidebar (Devices / Support / People / Activity / Settings), the list-first device view with side panels, per-topic Settings with search, and light/dark coverage across all 26 locales. The redesign was proposed in issue #493 (PR #495) and is implemented in BetterDesk's existing EJS/JavaScript/CSS stack rather than merged as a branch.
Design credit is recorded in docs/development/CONTRIBUTOR-ATTRIBUTIONS.md and shown in the console (Settings → General → Console interface).
License
AGPL-3.0. Optional Commercial Grant for eligible sponsors — docs/COMMERCIAL-GRANT.md.




