Registry data refreshed from vendors: Last vendor change detected: 5 Dec 2026Next refresh: 1st of the monthApp v1.4.0 (5 Dec 2026): Cleanup or tattoo: see what stays behind after a GPO is removed. Release notes
Windows (ADMX) · Scripts.admx

Scripts.admx: 12 policies

Generated from Microsoft Windows Server 2025 Datacenter build 26100 in-box templates + Windows 11 ADMX package (download id 108394) on 2026-12-05. Titles, explanations and "Supported on" text are Microsoft's own, from the en-US ADML file.

Allow logon scripts when NetBIOS or WINS is disabled

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows Vista

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameAllow-LogonScript-NetbiosDisabled
Enabled writes1 (REG_DWORD)
Disabled writes0 (REG_DWORD)
What it does (vendor explanation)

This policy setting allows user logon scripts to run when the logon cross-forest, DNS suffixes are not configured, and NetBIOS or WINS is disabled. This policy setting affects all user accounts interactively logging on to the computer.

If you enable this policy setting, user logon scripts run if NetBIOS or WINS is disabled during cross-forest logons without the DNS suffixes being configured.

If you disable or do not configure this policy setting, user account cross-forest, interactive logging cannot run logon scripts if NetBIOS or WINS is disabled, and the DNS suffixes are not configured.

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Allow logon scripts when NetBIOS or WINS is disabled

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'Allow-LogonScript-NetbiosDisabled' -Value 1 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Allow_Logon_Script_NetbiosDisabled

Display instructions in logoff scripts as they run

Per user Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameHideLogoffScripts
Enabled writes0 (REG_DWORD)
Disabled writes1 (REG_DWORD)
What it does (vendor explanation)

This policy setting displays the instructions in logoff scripts as they run.

Logoff scripts are batch files of instructions that run when the user logs off. By default, the system does not display the instructions in the logoff script.

If you enable this policy setting, the system displays each instruction in the logoff script as it runs. The instructions appear in a command window. This policy setting is designed for advanced users.

If you disable or do not configure this policy setting, the instructions are suppressed.

Group Policy path: User Configuration > Administrative Templates > System > Scripts > Display instructions in logoff scripts as they run

PowerShell equivalent (generated from the template)
New-Item -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'HideLogoffScripts' -Value 0 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Logoff_Script_Visible

Display instructions in logon scripts as they run

Per user Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameHideLogonScripts
Enabled writes0 (REG_DWORD)
Disabled writes1 (REG_DWORD)
What it does (vendor explanation)

This policy setting displays the instructions in logon scripts as they run.

Logon scripts are batch files of instructions that run when the user logs on. By default, the system does not display the instructions in logon scripts.

If you enable this policy setting, the system displays each instruction in the logon script as it runs. The instructions appear in a command window. This policy setting is designed for advanced users.

If you disable or do not configure this policy setting, the instructions are suppressed.

Group Policy path: User Configuration > Administrative Templates > System > Scripts > Display instructions in logon scripts as they run

PowerShell equivalent (generated from the template)
New-Item -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'HideLogonScripts' -Value 0 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Logon_Script_Visible

Display instructions in shutdown scripts as they run

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameHideShutdownScripts
Enabled writes0 (REG_DWORD)
Disabled writes1 (REG_DWORD)
What it does (vendor explanation)

This policy setting displays the instructions in shutdown scripts as they run.

Shutdown scripts are batch files of instructions that run when the user restarts the system or shuts it down. By default, the system does not display the instructions in the shutdown script.

If you enable this policy setting, the system displays each instruction in the shutdown script as it runs. The instructions appear in a command window.

If you disable or do not configure this policy setting, the instructions are suppressed.

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Display instructions in shutdown scripts as they run

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'HideShutdownScripts' -Value 0 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Shutdown_Script_Visible

Display instructions in startup scripts as they run

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameHideStartupScripts
Enabled writes0 (REG_DWORD)
Disabled writes1 (REG_DWORD)
What it does (vendor explanation)

This policy setting displays the instructions in startup scripts as they run.

Startup scripts are batch files of instructions that run before the user is invited to log on. By default, the system does not display the instructions in the startup script.

If you enable this policy setting, the system displays each instruction in the startup script as it runs. Instructions appear in a command window. This policy setting is designed for advanced users.

If you disable or do not configure this policy setting, the instructions are suppressed.

Note: Starting with Windows Vista operating system, scripts that are configured to run asynchronously are no longer visible on startup, whether this policy setting is enabled or not.

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Display instructions in startup scripts as they run

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'HideStartupScripts' -Value 0 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Startup_Script_Visible

Run Windows PowerShell scripts first at computer startup, shutdown

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows Server 2008 R2 or Windows 7

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameRunComputerPSScriptsFirst
Enabled writes1 (REG_DWORD)
Disabled writes0 (REG_DWORD)
What it does (vendor explanation)

This policy setting determines whether Windows PowerShell scripts are run before non-Windows PowerShell scripts during computer startup and shutdown. By default, Windows PowerShell scripts run after non-Windows PowerShell scripts.

If you enable this policy setting, within each applicable Group Policy Object (GPO), Windows PowerShell scripts are run before non-Windows PowerShell scripts during computer startup and shutdown.

For example, assume the following scenario:

There are three GPOs (GPO A, GPO B, and GPO C). This policy setting is enabled in GPO A.

GPO B and GPO C include the following computer startup scripts:

GPO B: B.cmd, B.ps1 GPO C: C.cmd, C.ps1

Assume also that there are two computers, DesktopIT and DesktopSales. For DesktopIT, GPOs A, B, and C are applied. Therefore, the scripts for GPOs B and C run in the following order for DesktopIT:

Within GPO B: B.ps1, B.cmd Within GPO C: C.ps1, C.cmd

For DesktopSales, GPOs B and C are applied, but not GPO A. Therefore, the scripts for GPOs B and C run in the following order for DesktopSales:

Within GPO B: B.cmd, B.ps1 Within GPO C: C.cmd, C.ps1

Note: This policy setting determines the order in which computer startup and shutdown scripts are run within all applicable GPOs. You can override this policy setting for specific script types within a specific GPO by configuring the following policy settings for the GPO:

Computer Configuration\Policies\Windows Settings\Scripts (Startup/Shutdown)\Startup Computer Configuration\Policies\Windows Settings\Scripts (Startup/Shutdown)\Shutdown

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Run Windows PowerShell scripts first at computer startup, shutdown

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'RunComputerPSScriptsFirst' -Value 1 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Computer_PS_Scripts_First

Run Windows PowerShell scripts first at user logon, logoff

Machine and user Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows Server 2008 R2 or Windows 7

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Registry keyHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameRunUserPSScriptsFirst
Enabled writes1 (REG_DWORD)
Disabled writes0 (REG_DWORD)
What it does (vendor explanation)

This policy setting determines whether Windows PowerShell scripts are run before non-Windows PowerShell scripts during user logon and logoff. By default, Windows PowerShell scripts run after non-Windows PowerShell scripts.

If you enable this policy setting, within each applicable Group Policy Object (GPO), PowerShell scripts are run before non-PowerShell scripts during user logon and logoff.

For example, assume the following scenario:

There are three GPOs (GPO A, GPO B, and GPO C). This policy setting is enabled in GPO A.

GPO B and GPO C include the following user logon scripts:

GPO B: B.cmd, B.ps1 GPO C: C.cmd, C.ps1

Assume also that there are two users, Qin Hong and Tamara Johnston. For Qin, GPOs A, B, and C are applied. Therefore, the scripts for GPOs B and C run in the following order for Qin:

Within GPO B: B.ps1, B.cmd Within GPO C: C.ps1, C.cmd

For Tamara, GPOs B and C are applied, but not GPO A. Therefore, the scripts for GPOs B and C run in the following order for Tamara:

Within GPO B: B.cmd, B.ps1 Within GPO C: C.cmd, C.ps1

Note: This policy setting determines the order in which user logon and logoff scripts are run within all applicable GPOs. You can override this policy setting for specific script types within a specific GPO by configuring the following policy settings for the GPO:

User Configuration\Policies\Windows Settings\Scripts (Logon/Logoff)\Logon User Configuration\Policies\Windows Settings\Scripts (Logon/Logoff)\Logoff

This policy setting appears in the Computer Configuration and User Configuration folders. The policy setting set in Computer Configuration takes precedence over the setting set in User Configuration.

Group Policy path: Computer or User Configuration > Administrative Templates > System > Scripts > Run Windows PowerShell scripts first at user logon, logoff

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'RunUserPSScriptsFirst' -Value 1 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_User_PS_Scripts_First

Run legacy logon scripts hidden

Per user Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameHideLegacyLogonScripts
Enabled writes1 (REG_DWORD)
Disabled writes0 (REG_DWORD)
What it does (vendor explanation)

This policy setting hides the instructions in logon scripts written for Windows NT 4.0 and earlier.

Logon scripts are batch files of instructions that run when the user logs on. By default, Windows 2000 displays the instructions in logon scripts written for Windows NT 4.0 and earlier in a command window as they run, although it does not display logon scripts written for Windows 2000.

If you enable this setting, Windows 2000 does not display logon scripts written for Windows NT 4.0 and earlier.

If you disable or do not configure this policy setting, Windows 2000 displays login scripts written for Windows NT 4.0 and earlier.

Also, see the "Run Logon Scripts Visible" setting.

Group Policy path: User Configuration > Administrative Templates > System > Scripts > Run legacy logon scripts hidden

PowerShell equivalent (generated from the template)
New-Item -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'HideLegacyLogonScripts' -Value 1 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Legacy_Logon_Script_Hidden

Run logon scripts synchronously

Per user Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameRunLogonScriptSync
What it does (vendor explanation)

This policy setting directs the system to wait for logon scripts to finish running before it starts the File Explorer interface program and creates the desktop.

If you enable this policy setting, File Explorer does not start until the logon scripts have finished running. This policy setting ensures that logon script processing is complete before the user starts working, but it can delay the appearance of the desktop.

If you disable or do not configure this policy setting, the logon scripts and File Explorer are not synchronized and can run simultaneously.

This policy setting appears in the Computer Configuration and User Configuration folders. The policy setting set in Computer Configuration takes precedence over the policy setting set in User Configuration.

Group Policy path: User Configuration > Administrative Templates > System > Scripts > Run logon scripts synchronously

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Logon_Script_Sync_1

Run logon scripts synchronously

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameRunLogonScriptSync
Enabled writes1 (REG_DWORD)
Disabled writes0 (REG_DWORD)
What it does (vendor explanation)

This policy setting directs the system to wait for logon scripts to finish running before it starts the File Explorer interface program and creates the desktop.

If you enable this policy setting, File Explorer does not start until the logon scripts have finished running. This policy setting ensures that logon script processing is complete before the user starts working, but it can delay the appearance of the desktop.

If you disable or do not configure this policy setting, the logon scripts and File Explorer are not synchronized and can run simultaneously.

This policy setting appears in the Computer Configuration and User Configuration folders. The policy setting set in Computer Configuration takes precedence over the policy setting set in User Configuration.

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Run logon scripts synchronously

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'RunLogonScriptSync' -Value 1 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Logon_Script_Sync_2

Run startup scripts asynchronously

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
Value nameRunStartupScriptSync
Enabled writes0 (REG_DWORD)
Disabled writes1 (REG_DWORD)
What it does (vendor explanation)

This policy setting lets the system run startup scripts simultaneously.

Startup scripts are batch files that run before the user is invited to log on. By default, the system waits for each startup script to complete before it runs the next startup script.

If you enable this policy setting, the system does not coordinate the running of startup scripts. As a result, startup scripts can run simultaneously.

If you disable or do not configure this policy setting, a startup cannot run until the previous script is complete.

Note: Starting with Windows Vista operating system, scripts that are configured to run asynchronously are no longer visible on startup, whether the ""Run startup scripts visible"" policy setting is enabled or not.

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Run startup scripts asynchronously

PowerShell equivalent (generated from the template)
New-Item -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Force | Out-Null
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'RunStartupScriptSync' -Value 0 -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name Run_Startup_Script_Sync

Specify maximum wait time for Group Policy scripts

Per machine Windows 11Windows Server 2025Windows Server 2022Windows Server 2019Windows Server 2016

Supported on: At least Windows 2000

When the GPO stops applying: Windows removes the value (it is under a Policies branch). How cleanup works

Registry keyHKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System
OptionValueTypeAllowed values
Seconds:MaxGPOScriptWaitREG_DWORDNumber 0 to 32000
What it does (vendor explanation)

This policy setting determines how long the system waits for scripts applied by Group Policy to run.

This setting limits the total time allowed for all logon, logoff, startup, and shutdown scripts applied by Group Policy to finish running. If the scripts have not finished running when the specified time expires, the system stops script processing and records an error event.

If you enable this setting, then, in the Seconds box, you can type a number from 1 to 32,000 for the number of seconds you want the system to wait for the set of scripts to finish. To direct the system to wait until the scripts have finished, no matter how long they take, type 0.

This interval is particularly important when other system tasks must wait while the scripts complete. By default, each startup script must complete before the next one runs. Also, you can use the ""Run logon scripts synchronously"" setting to direct the system to wait for the logon scripts to complete before loading the desktop.

An excessively long interval can delay the system and inconvenience users. However, if the interval is too short, prerequisite tasks might not be done, and the system can appear to be ready prematurely.

If you disable or do not configure this setting the system lets the combined set of scripts run for up to 600 seconds (10 minutes). This is the default.

Group Policy path: Computer Configuration > Administrative Templates > System > Scripts > Specify maximum wait time for Group Policy scripts

PowerShell equivalent (generated from the template)
# Seconds:
New-ItemProperty -Path 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System' -Name 'MaxGPOScriptWait' -Value <value> -PropertyType DWord -Force

Group Policy or Intune is the supported way to set policies. Writing the same values directly works like a local policy and is removed by nothing: delete the values to return to "Not configured".

Startup, Run keys and servicesADMX: Scripts.admx · policy name MaxGPOScriptWaitPolicy