en-US onedrive user

Prevent users from syncing personal OneDrive accounts

Verified with Microsoft OneDrive 26.153.0809.0004 — updated on September 2, 2026

Microsoft OneDrive 26.153.0809.0004

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

Path in the GPO console

User Configuration\Administrative Templates\OneDrive

Description

This setting lets you block users from signing in with a Microsoft account to sync their personal OneDrive files. If you enable this setting, users will be prevented from setting up a sync relationship for their personal OneDrive account. Users who are already syncing their personal OneDrive when you enable this setting won't be able to continue syncing (and will be shown a message that syncing has stopped), but any files synced to the computer will remain on the computer. OneDrive Photos and Microsoft Photos also honor this setting. If you enable this setting, photos from personal Microsoft accounts won't appear in the gallery. If you disable or do not configure this setting, users can sync their personal OneDrive accounts.

Registry

HKCU SOFTWARE\Policies\Microsoft\OneDrive

Value name: DisablePersonalSync

Enabled: DisablePersonalSync = 1

Disabled: DisablePersonalSync = 0

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: Prevent users from syncing personal OneDrive accounts
; State: Enabled
; Supported on: At least Windows Server 2008 R2 or Windows 7

[HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\OneDrive]
"DisablePersonalSync"=dword:00000001
More formats (PowerShell, Intune, SCCM)

PowerShell

# Exported from gporais.com
# Policy: Prevent users from syncing personal OneDrive accounts
# State: Enabled
# Supported on: At least Windows Server 2008 R2 or Windows 7
# Warning: In SYSTEM context (the Intune default), HKCU targets the SYSTEM profile. Run this script using the logged-on credentials.

$path = 'HKCU:\SOFTWARE\Policies\Microsoft\OneDrive'
New-Item -Path $path -Force | Out-Null
Set-ItemProperty -Path $path -Name 'DisablePersonalSync' -Value 1 -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