Where Windows Stores Mapped Network Drive Registry Keys
This article explains the exact Windows Registry location where user-specific mapped network drives and their persistent connection states are stored. It covers the specific registry path under the user hive, the individual values stored for each mapped drive letter, and how the operating system reads this information to restore network connections across user sessions.
The Registry Path for Persistent Network Drives
Windows records user-specific mapped network drives and their
persistence settings directly in the HKEY_CURRENT_USER
hive. The exact path is:
HKEY_CURRENT_USER\Network
Inside the Network key, Windows creates a dedicated
subkey for every drive letter mapped by the currently logged-in user
(for example, HKEY_CURRENT_USER\Network\Z for the
Z: drive).
Recorded Registry Values and Connection States
Each drive letter subkey contains several values that define how the connection behaves and where it connects:
- RemotePath (REG_SZ): Stores the Universal Naming
Convention (UNC) path to the shared network folder (e.g.,
\\ServerName\ShareName). - ProviderName (REG_SZ): Identifies the network
provider responsible for the share, typically set to
Microsoft Windows Networkfor standard SMB shares. - ProviderType (REG_DWORD): Specifies the network
provider type code used internally by the Windows network subsystem
(typically
0x00020000for Lanman/SMB). - ConnectionType (REG_DWORD): Defines the connection
resource type, where
1represents a standard redirected disk drive. - UserName (REG_SZ): Stores the specific username used to establish the connection if different credentials from the current logon session were supplied.
- DeferFlags (REG_DWORD): Manages connection restoration flags, including deferred or asynchronous reconnection behavior at system logon.
How Windows Uses This Data
When a user maps a drive with the “Reconnect at sign-in” option
enabled (or uses the
net use <Drive>: \\server\share /persistent:yes
command), Windows writes the configuration to
HKEY_CURRENT_USER\Network\<DriveLetter>.
During subsequent user logon events, the Windows shell queries this
registry location to restore the assigned drive letters and reconnect to
the specified network shares automatically. Removing a mapped drive via
File Explorer or the command line deletes the corresponding drive letter
key from HKEY_CURRENT_USER\Network.