Set roaming profile path for all users logging onto this computer: registry value MachineProfilePathComputerHKLM\Software\Policies\Microsoft\Windows\System
- Policy ID
- MachineProfilePath
- Scope
- Computer Configuration
- Supported on
- At least Windows Vista
- Source
- Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (version 1.0)
- Category
- System › User Profiles
Registry
MachineProfilePath
REG_EXPAND_SZComputerHKLM\Software\Policies\Microsoft\Windows\System Current key
- Enabled value
- Depends on the option value
- Element
- Users logging onto this computer should use this roaming profile path:
- Value type
- REG_EXPAND_SZ
- Maximum length
- 260
- Expandable string (REG_EXPAND_SZ)
- true
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\System] ; Value names and types follow the ADMX. Replace <enter value> below with your own data ; hex(2) and hex(7) data must be written as hexadecimal (UTF-16LE) "MachineProfilePath"=hex(2):<enter value>
CMD
:: Value names and types follow the ADMX. Replace <enter value> below with your own data reg add "HKLM\Software\Policies\Microsoft\Windows\System" /v "MachineProfilePath" /t REG_EXPAND_SZ /d "<enter value>" /f
PowerShell
# Value names and types follow the ADMX. Replace <enter value> below with your own data New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\System' -Force | Out-Null New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\System' -Name 'MachineProfilePath' -PropertyType ExpandString -Value '<enter value>' -Force | Out-Null