Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Windows App auto logoff is intended to be used in scenarios where the user connects from the Windows App connection center. It isn't supported for Windows 365 Boot, Windows 365 Switch or connections pinned to the Taskbar.
Note
Using any configuration of auto logoff can cause a slightly longer startup time because Windows App will need to retrieve the list of resources every time it opens.
Important
Windows App auto logoff is designed to manage user sessions and remove local app data based on inactivity or app closure, but it does not provide protection against unauthorized access or enforce security policies. Its primary purpose is operational convenience and data hygiene, not to serve as a security control or safeguard for sensitive information. Auto logoff erases local logs when triggered. For this reason, logs cannot be retrieved after Windows App has closed due to auto logoff and logging won't begin again until the app has re-opened. This can limit some troubleshooting capabilities.
Prerequisites
- Windows App installed on a supported version of Windows OS. To learn more see, Get started with Windows App.
Auto Logoff
Windows App auto logoff supports a variety of methods to initiate auto logoff. The following table outlines the key behaviors and system responses associated with Windows App auto logoff. It details how user data is handled, what the user experience looks like upon re-entry, and how inactivity is monitored and acted upon.
| Behavior | Description |
|---|---|
| Reset local data | All credentials, RDP files, and any other identifiable data will be removed from the Windows App caches on the local machine when Windows App auto logoff happens. This isn't user based and will remove all app data. |
| Sign in | After Windows App auto logoff, the user is directed to the sign in screen and will skip the first run experience (FRE) if configured to do so. |
| Inactivity signals | Windows App auto logoff will reference inactivity signals from Windows OS to determine when periods of inactivity occur. |
| Logoff interval | Once the timer starts, it runs for the duration set by the admin—for example, a value of 5 means Windows App will check the OS inactivity signals at 5 minutes. If the OS inactivity signal timer has a value of less than 5 minutes, then Windows App will check again in 5 more minutes. This could result in an actual time of up to 9:59, or twice the configured interval, before Windows App triggers the auto logoff process. |
| Closing Windows App | Upon manual closure of the Windows App auto logoff process is triggered. |
How to configure auto logoff
To configure the auto logoff feature in Windows App, set the following registry value(s) on your local Windows device. You can configure the registry key(s) using an enterprise deployment tool such as Intune, Configuration Manager, Group Policy, or PowerShell.
AutologoffEnable
This registry key will sign all users out of Windows App and resets app data when the user closes Windows App. It doesn't impact active Azure Virtual Desktop or Windows 365 sessions.
This behavior will automatically be enabled if either AutoLogoffOnSuccessfulConnect or AutoLogoffTimeInterval are set.
- Value: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WindowsApp
- Type: REG_DWORD
- Name: AutoLogoffEnable
- Data
- 0: disables all auto logoff behavior and overrides values set in AutoLogoffOnSuccessfulConnect and AutoLogoffTimeInterval if present
- 1: enabled
AutoLogoffOnSuccessfulConnect
This registry key will sign all users out of Windows App and reset app data when a successful connection to an Azure Virtual Desktop session host or Windows 365 Cloud PC is made. It doesn't impact active Azure Virtual Desktop or Windows 365 sessions.
- Value: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WindowsApp
- Type: REG_DWORD
- Name: AutoLogoffOnSuccessfulConnect
- Data
- 0: disabled
- 1: enabled only if AutoLogoffEnable is set to 1 or isn't present
AutoLogoffTimeInterval
This registry key determines the interval at which Windows App checks the Windows OS for inactivity. For example, if set to 5, the app will poll the OS for inactivity every 5 minutes and the logout process will initiate if the OS reports 5 or more minutes of inactivity. Additionally, if a user manually closes the app, auto logoff is triggered immediately upon shutdown, clearing relevant app data.
- Value: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WindowsApp
- Type: REG_DWORD
- Name: AutoLogoffTimeInterval
- Data
- 0: disabled
- Time interval in minutes (ex: 5 for 5 minutes): enabled only if AutoLogoffEnable is set to 1 or isn't present
SkipFRE
When auto logoff is triggered, the next launch of the Windows App initiates the First Run Experience (FRE). However, in some scenarios launching FRE is undesirable, as it forces users to repeat the initial setup process unnecessarily.
To prevent this and streamline the user experience, the following registry value should be added:
- Value: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows365
- Type: REG_DWORD
- Name: SkipFRE
- Data: integer, 1 for disabling the FRE
Note
The script below will set the auto logoff interval to 1 minute. Please change the number after "-Value" to a different integer to modify the interval time. These values can be replaced with any combination of registry key and value as outlined above.
To set this registry value using PowerShell:
Close Windows App if it's open.
Open a PowerShell prompt as an administrator, then run the following command:
$path = "HKLM:\SOFTWARE\Microsoft\WindowsApp" If (!(Test-Path $path)) { New-Item -Path $path -Force } New-ItemProperty -Path $path -Name AutoLogoffTimeInterval -PropertyType DWORD -Value 1 -Force
Example scenarios for auto logoff
In this section, there are scenarios that show how different settings of auto logoff work. In each example, there are tables that show the configured registry settings.
Scenario 1: Log the user out of Windows App and reset Windows App only when the app is closed
In this scenario, the admin intends to configure Windows App so that it logs off and resets only when the user closes the app, while also hiding the First Run Experience (FRE).
With the settings configured as described below, users will log in to the Windows App and immediately access their resources without undergoing FRE. Users can connect to their resources, close and reopen connections, leave their machines for some time and remain signed in on the Windows App. When users close the Windows App, it will automatically log them off and reset the application.
| Registry | Value |
|---|---|
| AutoLogoffEnable | 1 |
| SkipFRE | 1 |
Scenario 2: Log the user out of Windows App and reset Windows App only after a user has successfully initiated a connection
In this scenario, the admin intends to configure Windows App so that it logs off and resets only when the user has successfully connected to a resource, while also hiding the First Run Experience (FRE).
With the settings configured as described below, users will log in to the Windows App and immediately access their resources without undergoing FRE. Upon establishing their first successful connection to a resource, the user will automatically be logged off from the Windows App and also reset the application in the background. The resource to which the user has connected will remain unaffected.
| Registry | Value |
|---|---|
| AutoLogoffOnSuccessfulConnect | 1 |
| SkipFRE | 1 |
Scenario 3: Log the user out of Windows App and reset Windows App based only on a minimum of 5 minutes of user inactivity
In this scenario, the admin intends to configure Windows App so that it logs off and resets only when the user has been inactive for a minimum of 5 minutes, while also hiding the First Run Experience (FRE).
With the settings configured as described below, users will log in to the Windows App and directly access their resources without undergoing FRE. Users can connect to their resources, close and reopen connections, and remain signed in on the Windows App. When the user is away from their computer and after the computer has been idle for at least 5 minutes, the Windows App will automatically log them off and reset the application. Any active session won't be affected unless the admin has also configured the session idle settings on the remote resource.
| Registry | Value |
|---|---|
| AutoLogoffTimeInterval | 5 |
| SkipFRE | 1 |
Scenario 4: Log off user and reset Windows App when Windows App is closed or based on a minimum of 10 minutes of user inactivity
In this scenario, the admin intends to configure Windows App so that it logs off and resets when the user has been inactive for a minimum of 10 minutes or when the user closes the app, while also hiding the First Run Experience (FRE).
With the settings configured as described below, users will log in to the Windows App and directly access their resources without undergoing FRE. Users can connect to their resources, close and reopen connections, and remain signed in on the Windows App. When the user is away from their computer and after the computer has been idle for at least 10 minutes or when the user closes the Windows App, the Windows App will automatically log them off and reset the application. Any active session won't be affected unless the admin has also configured the session idle settings on the remote resource.
| Registry | Value |
|---|---|
| AutoLogoffEnable | 1 |
| AutoLogoffTimeInterval | 10 |
| SkipFRE | 1 |
Scenario 5: Disable any auto logoff on Windows App on Windows
In this scenario, the admin intends to disable the auto logoff feature on the Windows App and enable the First Run Experience (FRE). This represents the default configuration upon installation of the Windows App.
According to the settings specified below, when users log in to the Windows App for the first time, they will encounter the FRE process before gaining access to their resources. Subsequently, users will be able to connect to their resources, close and reopen connections, close and reopen the Windows App, and leave their computer idle while remaining signed into the Windows App.
| Registry | Value |
|---|---|
| AutoLogoffEnable | 0 |
| SkipFRE | 0 |