Multi-Server
Connecting to multiple Gryt servers
Gryt clients can connect to multiple servers at the same time. Each server is an independent instance with its own channels, members, and configuration. The client manages connections separately, keyed by the server's host address.
How it works
When you add a server, the client opens a Socket.IO connection to that server's address. You can add as many servers as you like — each one gets its own entry in the sidebar, and you switch between them by clicking. Only one server is "active" (visible) at a time, but connections to other servers stay open in the background so you receive notifications and presence updates.
There is no state sync between servers. Each server is fully independent — your channels, roles, and voice sessions are per-server.
Adding a server
Manual
- Click the + button in the server sidebar
- Enter the server address (e.g.
my-server.example.com:5000) - Click Connect — the client fetches the server info via HTTP
- Click Join to complete the handshake
LAN discovery (desktop app only)
The desktop app automatically discovers Gryt servers on your local network using mDNS (multicast DNS). Servers advertise themselves as _gryt._tcp services, and the client listens for these announcements.
When a server is found on the LAN, it appears in the Local Servers section of the Add Server dialog. Click Connect to fetch its info and join — no need to type an IP address.
LAN discovery only works in the desktop (Electron) app. Browsers cannot perform mDNS queries, so the web app always requires manual entry.
How mDNS works
- The server publishes a
_gryt._tcpmDNS service on startup - On Linux with avahi-daemon (default on Debian/Ubuntu), it writes a service file to
/etc/avahi/services/— this is the most reliable method - If avahi is not available, it falls back to the
bonjour-servicenpm package - The Electron client browses for
_gryt._tcpservices and displays any it finds - When a server shuts down, it removes the service
Server configuration
mDNS advertisement uses the existing SERVER_NAME environment variable. The name shown during discovery is whatever you set as SERVER_NAME in your server config.
For Docker deployments with avahi (recommended):
- Ensure
avahi-daemonis running on the host - Run
chmod o+w /etc/avahi/serviceson the host (one-time) - The compose file mounts
/etc/avahi/servicesinto the container automatically
LAN open join (skip invite codes on LAN)
By default, every new user must use an invite code to join a server. For LAN parties and local events, you can enable LAN open join so anyone on the same local network can join without an invite code. Remote connections from the internet still require an invite.
To enable it, go to Server Settings → Overview and toggle Allow anyone on LAN to join. This setting is dynamic — it takes effect immediately with no server restart.
When enabled, the server checks the connecting client's IP address. If it falls within a private/LAN range (10.x.x.x, 172.16–31.x.x, 192.168.x.x, or IPv6 link-local/unique-local), the invite requirement is skipped. Clients connecting from public IPs are still required to use an invite code.
LAN open join works with both manual connections and mDNS discovery. When a LAN-discovered server has this setting enabled, the desktop app skips the invite code prompt entirely — users just click Connect and Join.
If your server is behind a reverse proxy, make sure X-Forwarded-For is set correctly. Otherwise the server may see the proxy's IP instead of the client's real IP, which could bypass or prevent the LAN detection.
Removing a server
Right-click a server in the sidebar and select Remove, or go to Settings → Servers and remove it from there. This closes the connection and removes it from your saved server list.