Set Remote Desktop Services User Home Directory: registry value WFHomeDirUNC and 2 moreComputerHKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services
- Policy ID
- TS_USER_HOME
- Scope
- Computer Configuration
- Supported on
- At least Windows Server 2003
- Source
- Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (version 1.0)
- Category
- Windows Components › Remote Desktop Services › Remote Desktop Session Host › Profiles
Registry
WFHomeDirUNC
REG_DWORDComputer- Enabled value
- Depends on the option value
- Element
- Location:
| Item | Stored value |
|---|---|
| On the Network | 1 |
| On the Local machine | 0 |
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services] ; Options (use only one) ; On the Network "WFHomeDirUNC"=dword:00000001 ; On the Local machine "WFHomeDirUNC"=dword:00000000
CMD
:: Options (use only one) :: On the Network reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirUNC" /t REG_DWORD /d 1 /f :: On the Local machine reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirUNC" /t REG_DWORD /d 0 /f
PowerShell
# Common: create the key New-Item -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Force | Out-Null # Options (use only one) # On the Network New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirUNC' -PropertyType DWord -Value 1 -Force | Out-Null # On the Local machine New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirUNC' -PropertyType DWord -Value 0 -Force | Out-Null
WFHomeDir
REG_SZComputer- Enabled value
- Depends on the option value
- Element
- Home Dir Root Path:
- Value type
- REG_SZ
- Required
- true
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services] ; Value names and types follow the ADMX. Replace <enter value> below with your own data "WFHomeDir"="<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 NT\Terminal Services" /v "WFHomeDir" /t REG_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 NT\Terminal Services' -Force | Out-Null New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDir' -PropertyType String -Value '<enter value>' -Force | Out-Null
WFHomeDirDrive
REG_SZComputer- Enabled value
- Depends on the option value
- Element
- Drive Letter
| Item | Stored value |
|---|---|
| G: | G: |
| H: | H: |
| I: | I: |
| J: | J: |
| K: | K: |
| L: | L: |
| M: | M: |
| N: | N: |
| O: | O: |
| P: | P: |
| Q: | Q: |
| R: | R: |
| S: | S: |
| T: | T: |
| U: | U: |
| V: | V: |
| W: | W: |
| X: | X: |
| Y: | Y: |
| Z: | Z: |
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services] ; Options (use only one) ; G: "WFHomeDirDrive"="G:" ; H: "WFHomeDirDrive"="H:" ; I: "WFHomeDirDrive"="I:" ; J: "WFHomeDirDrive"="J:" ; K: "WFHomeDirDrive"="K:" ; L: "WFHomeDirDrive"="L:" ; M: "WFHomeDirDrive"="M:" ; N: "WFHomeDirDrive"="N:" ; O: "WFHomeDirDrive"="O:" ; P: "WFHomeDirDrive"="P:" ; Q: "WFHomeDirDrive"="Q:" ; R: "WFHomeDirDrive"="R:" ; S: "WFHomeDirDrive"="S:" ; T: "WFHomeDirDrive"="T:" ; U: "WFHomeDirDrive"="U:" ; V: "WFHomeDirDrive"="V:" ; W: "WFHomeDirDrive"="W:" ; X: "WFHomeDirDrive"="X:" ; Y: "WFHomeDirDrive"="Y:" ; Z: "WFHomeDirDrive"="Z:"
CMD
:: Options (use only one) :: G: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "G:" /f :: H: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "H:" /f :: I: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "I:" /f :: J: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "J:" /f :: K: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "K:" /f :: L: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "L:" /f :: M: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "M:" /f :: N: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "N:" /f :: O: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "O:" /f :: P: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "P:" /f :: Q: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "Q:" /f :: R: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "R:" /f :: S: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "S:" /f :: T: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "T:" /f :: U: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "U:" /f :: V: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "V:" /f :: W: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "W:" /f :: X: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "X:" /f :: Y: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "Y:" /f :: Z: reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v "WFHomeDirDrive" /t REG_SZ /d "Z:" /f
PowerShell
# Common: create the key New-Item -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Force | Out-Null # Options (use only one) # G: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'G:' -Force | Out-Null # H: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'H:' -Force | Out-Null # I: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'I:' -Force | Out-Null # J: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'J:' -Force | Out-Null # K: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'K:' -Force | Out-Null # L: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'L:' -Force | Out-Null # M: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'M:' -Force | Out-Null # N: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'N:' -Force | Out-Null # O: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'O:' -Force | Out-Null # P: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'P:' -Force | Out-Null # Q: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'Q:' -Force | Out-Null # R: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'R:' -Force | Out-Null # S: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'S:' -Force | Out-Null # T: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'T:' -Force | Out-Null # U: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'U:' -Force | Out-Null # V: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'V:' -Force | Out-Null # W: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'W:' -Force | Out-Null # X: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'X:' -Force | Out-Null # Y: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'Y:' -Force | Out-Null # Z: New-ItemProperty -Path 'HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services' -Name 'WFHomeDirDrive' -PropertyType String -Value 'Z:' -Force | Out-Null