en-US windows computer

Configure maintenance windows for automatic updates

Verified with Windows 11 25H2 — updated on September 15, 2026 Supported on: At least Windows 11 Version 24H2

Windows 11 25H2

KB5124008

Shipped in a Windows update: not in the official ADMX package (Administrative Templates (.admx) for Windows 11 Oct 2025 Update), present no later than KB5124008 (build 26200.9445).

Path in the GPO console

Computer Configuration\Administrative Templates\Windows Components\Windows Update\Manage end user experience

Registry

HKLM Software\Policies\Microsoft\Windows\WindowsUpdate
Value name:
MaintenanceWindowEnabled REG_DWORD
Enabled:
1
Disabled:
0

Options

Update actions only allowed inside the maintenance window:
MaintenanceWindowUpdateActions enum
  • 1 Download, install, and restart
  • 2 Install and restart default
  • 3 Restart only
Start date (Format: yyyy-mm-dd example: 2025-10-30)
MaintenanceWindowStartDate text
Start time (Format: hh:mm example: 23:30 for 11:30 PM)
MaintenanceWindowStartTime text
Duration (hours):
MaintenanceWindowDurationHours decimal range 2-24 default: 2
Select repeat schedule:
MaintenanceWindowRepeatScheduleOption enum
  • 1 No repeat
  • 2 Daily default
  • 3 Weekly
  • 4 Monthly
Sunday
MaintenanceWindowWeeklySunday boolean default: 0
Monday
MaintenanceWindowWeeklyMonday boolean default: 0
Tuesday
MaintenanceWindowWeeklyTuesday boolean default: 0
Wednesday
MaintenanceWindowWeeklyWednesday boolean default: 0
Thursday
MaintenanceWindowWeeklyThursday boolean default: 0
Friday
MaintenanceWindowWeeklyFriday boolean default: 0
Saturday
MaintenanceWindowWeeklySaturday boolean default: 0
Monthly Schedule Type:
MaintenanceWindowMonthlySchedule enum
  • 1 Date-based
  • 2 Week-based default
  • 3 Last day of the month
Day of the Month:
MaintenanceWindowMonthlyMonthBasedDayOfMonth decimal range 1-28 default: 1
Occurrence in Month
MaintenanceWindowMonthlyWeekBasedOccurrenceInMonth enum
  • 1 First
  • 2 Second default
  • 3 Third
  • 4 Fourth
  • 5 Last
Day of the Week
MaintenanceWindowMonthlyWeekBasedDayOfTheWeek enum
  • 1 Sunday
  • 2 Monday default
  • 3 Tuesday
  • 4 Wednesday
  • 5 Thursday
  • 6 Friday
  • 7 Saturday

Description

Enable this policy to specify repeatable maintenance windows for the device to perform specified update actions. When this policy is enabled, Windows Update will only perform the specified update action during the configured maintenance window. Specified update actions outside maintenance window will be deferred until the next maintenance window begins. • Update Actions: Select which update actions are only allowed during maintenance window. If an update action is not selected, that action can happen outside of maintenance window. - Download, install, and restart: Complete update cycle including download, installation, and system restart - Install and restart: Install already downloaded updates and restart the device - Restart only: Only perform a system restart for pending updates • Basic Schedule Configuration: - Start Date: Specify the initial date when the first maintenance window begins (format: yyyy-mm-dd, example: 2025-10-30) * Start Date field only takes effect if Recurring schedule is set to “None” - Start Time: Set the time when the maintenance window starts (format: hh:mm, example: 23:30 for 11:30 PM) - Duration: Define how long each maintenance window lasts in hours (example: 2 for a 2-hour window) • Recurring Schedule Options: - No repeat: One-time maintenance window on the specified start date only - Daily: Maintenance window will be repeated every day - Weekly: Maintenance window will be repeated weekly on selected days of the week - Monthly: Maintenance window will be repeated monthly on a specific day • Weekly Schedule Settings (when Weekly is selected): - Day of the week Selection: Choose which days of the week the maintenance window occurs: * Sunday through Saturday: Check boxes to select specific day(s) of the week for the maintenance window • Monthly Schedule Settings (when Monthly is selected): - Monthly Schedule Type: * Date-based: Maintenance window occurs on a specific day of the month (example: 15th day of each month) * Week-based: Maintenance window occurs on a specific weekday occurrence within the month (example: 2nd Tuesday of each month) * Last day of the month: Maintenance window occurs on the last day of the month - Day of Month: When using date-based scheduling, specify which day of the month (1-28) - Occurrence in Month: When using week-based scheduling, select which week of the month (First, Second, Third, Fourth, or Last) - Day of the Week: When using week-based scheduling, select which day of the week (Sunday through Saturday) Examples of Monthly Configurations: - Date-based: "3rd day of every month" = Day of Month: 3 - Week-based: "Second Tuesday of every month" = Occurrence: Second, Day of Week: Tuesday - Week-based: "Last Friday of every month" = Occurrence: Last, Day of Week: Friday - Last day of the month: "Last day of every month" After a non-repeating maintenance window occurs, the next maintenance window must be scheduled in 3 months. If the start date of a non-repeating maintenance window is more than 3 months in the past, this policy will be disregarded, and updates will be scheduled according to default settings. If you disable or do not configure this policy, Windows Update will follow its default scheduling behavior.

Export Builder

BETA

Configure the state, scope and options, then generate .reg, PowerShell, Intune and SCCM outputs — or add the setting to a multi-setting collection.

These exports write the registry — this is not a managed GPO. ⓘ

.reg file

Windows Registry Editor Version 5.00

; Exported from gporais.com
; Policy: Configure maintenance windows for automatic updates
; State: Enabled
; Supported on: At least Windows 11 Version 24H2

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\WindowsUpdate]
"MaintenanceWindowEnabled"=dword:00000001
"MaintenanceWindowUpdateActions"=dword:00000002
"MaintenanceWindowStartDate"=""
"MaintenanceWindowStartTime"=""
"MaintenanceWindowDurationHours"=dword:00000002
"MaintenanceWindowRepeatScheduleOption"=dword:00000002
"MaintenanceWindowWeeklySunday"=dword:00000000
"MaintenanceWindowWeeklyMonday"=dword:00000000
"MaintenanceWindowWeeklyTuesday"=dword:00000000
"MaintenanceWindowWeeklyWednesday"=dword:00000000
"MaintenanceWindowWeeklyThursday"=dword:00000000
"MaintenanceWindowWeeklyFriday"=dword:00000000
"MaintenanceWindowWeeklySaturday"=dword:00000000
"MaintenanceWindowMonthlySchedule"=dword:00000002
"MaintenanceWindowMonthlyMonthBasedDayOfMonth"=dword:00000001
"MaintenanceWindowMonthlyWeekBasedOccurrenceInMonth"=dword:00000002
"MaintenanceWindowMonthlyWeekBasedDayOfTheWeek"=dword:00000002
More formats (PowerShell, Intune, SCCM)

PowerShell

# Exported from gporais.com
# Policy: Configure maintenance windows for automatic updates
# State: Enabled
# Supported on: At least Windows 11 Version 24H2

$path = 'HKLM:\Software\Policies\Microsoft\Windows\WindowsUpdate'
New-Item -Path $path -Force | Out-Null
Set-ItemProperty -Path $path -Name 'MaintenanceWindowEnabled' -Value 1 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowUpdateActions' -Value 2 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowStartDate' -Value '' -Type String
Set-ItemProperty -Path $path -Name 'MaintenanceWindowStartTime' -Value '' -Type String
Set-ItemProperty -Path $path -Name 'MaintenanceWindowDurationHours' -Value 2 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowRepeatScheduleOption' -Value 2 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklySunday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklyMonday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklyTuesday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklyWednesday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklyThursday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklyFriday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowWeeklySaturday' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowMonthlySchedule' -Value 2 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowMonthlyMonthBasedDayOfMonth' -Value 1 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowMonthlyWeekBasedOccurrenceInMonth' -Value 2 -Type DWord
Set-ItemProperty -Path $path -Name 'MaintenanceWindowMonthlyWeekBasedDayOfTheWeek' -Value 2 -Type DWord

Building a multi-setting collection? Add this setting and generate combined .reg / PowerShell / GPO scripts.

Open the Builder

Embed this policy on your site

What to embed
Theme

Adds one script line: the theme follows your site’s appearance and the height fits the content. If your site blocks scripts, the embed follows the visitor’s system theme.

Preview