Terminal Sync
Terminal sync makes a local terminal accessible from the web. Sync is opt-in and per-terminal — you choose exactly which terminals are available remotely.
Sync a terminal
Section titled “Sync a terminal”kexsh terminal sync <id|name>$ kexsh terminal sync devTerminal synced: dev (a3f) ✓→ Access at app.kex.shThe CLI opens a persistent WebSocket connection to the cloud relay. Terminal I/O is forwarded bidirectionally in real-time.
Unsync a terminal
Section titled “Unsync a terminal”kexsh terminal unsync <id|name>$ kexsh terminal unsync devTerminal unsynced: dev (a3f)The terminal continues running locally but is no longer accessible remotely.
Check sync status
Section titled “Check sync status”Synced terminals show their status in kexsh terminal ls:
kexsh terminal lsID NAME STATUS SYNC CREATEDa3f dev running synced 5 minutes agob7c — running local 2 minutes agoHow sync works
Section titled “How sync works”When you sync a terminal, the kexsh server:
- Opens a WebSocket connection to the cloud relay (
wss://api.kex.sh) - Authenticates using your stored session token
- Registers the terminal with the relay
- Forwards all terminal I/O over the encrypted connection
The connection automatically reconnects if interrupted. On reconnect, the CLI sends a full status update so the relay knows which terminals are still synced.
See also
Section titled “See also”- Cloud Overview — architecture and principles
- Web Terminal — access synced terminals in the browser
- kexsh terminal — terminal command reference