To keep the Remote Desktop session from disconnecting so quickly when idle, increase or remove the session time limits on the server (or via policy), and ensure the idle timeout values are not set too low.
Use one of these approaches (typically done on the remote/server side):
- Configure RDS session time limits via Group Policy
- On the remote computer or domain controller, open gpedit.msc (local) or gpmc.msc (domain).
- Go to: Computer Configuration → Administrative Templates → Windows Components → Remote Desktop Services → Remote Desktop Session Host → Session Time Limits.
- Configure these policies as needed:
- Set time limit for active but idle Remote Desktop Services sessions → set to a higher value or to Never.
- Set time limit for active Remote Desktop Services sessions (if used) → increase or set appropriately.
- Set time limit for disconnected sessions → increase if sessions are being dropped too quickly after disconnect.
- Run
gpupdate /forceor reboot to apply.
- Adjust session limits in the RDS Collection (RDS deployments)
- On the server that manages the RDS deployment (usually the Remote Desktop Connection Broker), open Server Manager → Remote Desktop Services.
- Select the Collection that hosts the session.
- Under Properties tasks, open Session.
- Increase the values for idle and active session limits, or disable them if appropriate.
- These settings update the registry under:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp(for example,MaxIdleTimeandMaxConnectionTime).
- For Windows 10/11 clients managed via MDM/Intune
- Use the TS_SESSIONS_Disconnected_Timeout_1 policy (ADMX_TerminalServer CSP) to control how long disconnected sessions remain active. Set a longer timeout or Never if disconnected sessions are ending too quickly.
If disconnects are irregular (not at a consistent time interval), they may be due to network issues rather than these timeout settings.
References: