Configure Background Sync
Verified with Windows 11 25H2 — updated on July 30, 2026
Supported on: At least Windows Server 2008 R2 or Windows 7
Path in the GPO console
Computer Configuration\Administrative Templates\Network\Offline Files Description
This policy setting controls when background synchronization occurs while operating in slow-link mode, and applies to any user who logs onto the specified machine while this policy is in effect. To control slow-link mode, use the "Configure slow-link mode" policy setting. If you enable this policy setting, you can control when Windows synchronizes in the background while operating in slow-link mode. Use the 'Sync Interval' and 'Sync Variance' values to override the default sync interval and variance settings. Use 'Blockout Start Time' and 'Blockout Duration' to set a period of time where background sync is disabled. Use the 'Maximum Allowed Time Without A Sync' value to ensure that all network folders on the machine are synchronized with the server on a regular basis. You can also configure Background Sync for network shares that are in user selected Work Offline mode. This mode is in effect when a user selects the Work Offline button for a specific share. When selected, all configured settings will apply to shares in user selected Work Offline mode as well. If you disable or do not configure this policy setting, Windows performs a background sync of offline folders in the slow-link mode at a default interval with the start of the sync varying between 0 and 60 additional minutes. In Windows 7 and Windows Server 2008 R2, the default sync interval is 360 minutes. In Windows 8 and Windows Server 2012, the default sync interval is 120 minutes.
Registry
Software\Policies\Microsoft\Windows\NetCache Value name: BackgroundSyncEnabled
Enabled: BackgroundSyncEnabled = 1
Disabled: BackgroundSyncEnabled = 0
MDM / Intune (CSP)
./Device/Vendor/MSFT/Policy/Config/ADMX_OfflineFiles/Pol_BackgroundSyncSettings Microsoft Learn documentation Mapping data: Microsoft Learn (CC BY 4.0)
Export Builder
BETAConfigure 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 Background Sync
; State: Enabled
; Supported on: At least Windows Server 2008 R2 or Windows 7
[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\NetCache]
"BackgroundSyncEnabled"=dword:00000001
"BackgroundSyncPeriodMin"=dword:00000168
"BackgroundSyncMaxStartMin"=dword:0000003c
"BackgroundSyncIgnoreBlockOutAfterMin"=dword:00000000
"BackgroundSyncBlockOutStartTime"=dword:00000000
"BackgroundSyncBlockOutDurationMin"=dword:00000000
"BackgroundSyncEnabledForForcedOffline"=dword:00000000 More formats (PowerShell, Intune, SCCM)
PowerShell
# Exported from gporais.com
# Policy: Configure Background Sync
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
$path = 'HKLM:\Software\Policies\Microsoft\Windows\NetCache'
New-Item -Path $path -Force | Out-Null
Set-ItemProperty -Path $path -Name 'BackgroundSyncEnabled' -Value 1 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncPeriodMin' -Value 360 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncMaxStartMin' -Value 60 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncIgnoreBlockOutAfterMin' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncBlockOutStartTime' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncBlockOutDurationMin' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncEnabledForForcedOffline' -Value 0 -Type DWord Intune XML
OMA-URI: ./Device/Vendor/MSFT/Policy/Config/ADMX_OfflineFiles/Pol_BackgroundSyncSettings
Data type: String
Value:
<enabled/>
<data id="Lbl_BackgroundSyncDefaultSyncTime" value="360"/>
<data id="Lbl_BackgroundSyncVariance" value="60"/>
<data id="Lbl_BackgroundSyncIgnoreBlockOutTime" value="0"/>
<data id="Lbl_BackgroundSyncBlockOutPeriodStartTime" value="0"/>
<data id="Lbl_BackgroundSyncBlockOutPeriodDuration" value="0"/>
<data id="Lbl_BackgroundSyncInForcedOffline" value="0"/> Intune Remediation
# === Detection script ===
# Exported from gporais.com
# Policy: Configure Background Sync
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
function Test-RegistryValue {
param(
[Parameter(Mandatory = $true)][string]$Path,
[Parameter(Mandatory = $true)][string]$Name,
[object]$Expected,
[ValidateSet('String', 'DWord', 'MultiString')][string]$Kind = 'String',
[switch]$Absent
)
try {
$item = Get-ItemProperty -LiteralPath $Path -Name $Name -ErrorAction Stop
} catch {
return $Absent.IsPresent
}
if ($Absent.IsPresent) { return $false }
$actual = $item.$Name
if ($Kind -eq 'DWord') { return ([int64]$actual) -eq ([int64]$Expected) }
if ($Kind -eq 'MultiString') {
$actualValues = @($actual)
$expectedValues = @($Expected)
if ($actualValues.Count -ne $expectedValues.Count) { return $false }
for ($i = 0; $i -lt $expectedValues.Count; $i++) {
if ([string]$actualValues[$i] -ne [string]$expectedValues[$i]) { return $false }
}
return $true
}
return [string]$actual -eq [string]$Expected
}
$checks = @(
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncEnabled' -Expected 1 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncPeriodMin' -Expected 360 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncMaxStartMin' -Expected 60 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncIgnoreBlockOutAfterMin' -Expected 0 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncBlockOutStartTime' -Expected 0 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncBlockOutDurationMin' -Expected 0 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncEnabledForForcedOffline' -Expected 0 -Kind DWord)
)
if ($checks -notcontains $false) {
Write-Output 'Compliant'
exit 0
}
Write-Output 'Non-compliant'
exit 1
# === Remediation script ===
# Exported from gporais.com
# Policy: Configure Background Sync
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
$path = 'HKLM:\Software\Policies\Microsoft\Windows\NetCache'
New-Item -Path $path -Force | Out-Null
Set-ItemProperty -Path $path -Name 'BackgroundSyncEnabled' -Value 1 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncPeriodMin' -Value 360 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncMaxStartMin' -Value 60 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncIgnoreBlockOutAfterMin' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncBlockOutStartTime' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncBlockOutDurationMin' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncEnabledForForcedOffline' -Value 0 -Type DWord SCCM scripts
# Exported from gporais.com
# Policy: Configure Background Sync
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
# SCCM Configuration Item guidance:
# Create a Configuration Item of type "Setting: Script".
# Discovery script: use the Detection script below.
# Remediation script: use the Remediation script below.
# Compliance rule: the Discovery script output equals 'Compliant'.
# === Detection script ===
# Exported from gporais.com
# Policy: Configure Background Sync
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
function Test-RegistryValue {
param(
[Parameter(Mandatory = $true)][string]$Path,
[Parameter(Mandatory = $true)][string]$Name,
[object]$Expected,
[ValidateSet('String', 'DWord', 'MultiString')][string]$Kind = 'String',
[switch]$Absent
)
try {
$item = Get-ItemProperty -LiteralPath $Path -Name $Name -ErrorAction Stop
} catch {
return $Absent.IsPresent
}
if ($Absent.IsPresent) { return $false }
$actual = $item.$Name
if ($Kind -eq 'DWord') { return ([int64]$actual) -eq ([int64]$Expected) }
if ($Kind -eq 'MultiString') {
$actualValues = @($actual)
$expectedValues = @($Expected)
if ($actualValues.Count -ne $expectedValues.Count) { return $false }
for ($i = 0; $i -lt $expectedValues.Count; $i++) {
if ([string]$actualValues[$i] -ne [string]$expectedValues[$i]) { return $false }
}
return $true
}
return [string]$actual -eq [string]$Expected
}
$checks = @(
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncEnabled' -Expected 1 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncPeriodMin' -Expected 360 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncMaxStartMin' -Expected 60 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncIgnoreBlockOutAfterMin' -Expected 0 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncBlockOutStartTime' -Expected 0 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncBlockOutDurationMin' -Expected 0 -Kind DWord)
(Test-RegistryValue -Path 'HKLM:\Software\Policies\Microsoft\Windows\NetCache' -Name 'BackgroundSyncEnabledForForcedOffline' -Expected 0 -Kind DWord)
)
if ($checks -notcontains $false) {
Write-Output 'Compliant'
exit 0
}
Write-Output 'Non-compliant'
exit 1
# === Remediation script ===
# Exported from gporais.com
# Policy: Configure Background Sync
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
$path = 'HKLM:\Software\Policies\Microsoft\Windows\NetCache'
New-Item -Path $path -Force | Out-Null
Set-ItemProperty -Path $path -Name 'BackgroundSyncEnabled' -Value 1 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncPeriodMin' -Value 360 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncMaxStartMin' -Value 60 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncIgnoreBlockOutAfterMin' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncBlockOutStartTime' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncBlockOutDurationMin' -Value 0 -Type DWord
Set-ItemProperty -Path $path -Name 'BackgroundSyncEnabledForForcedOffline' -Value 0 -Type DWord Building a multi-setting collection? Add this setting and generate combined .reg / PowerShell / GPO scripts.