Networking · How-To

How to Map a Network Drive in Windows 11

By , Editor · · Networking
The short answer

Open File Explorer, click This PC, open the three-dot menu and choose Map network drive. Pick a free drive letter, type the shared folder’s path in the form \\ComputerName\ShareName, tick Reconnect at sign-in, and click Finish. The share then appears under This PC with its own drive letter, just like a local disk.

Mapping turns a folder on another computer or NAS into a familiar drive letter, so apps and File Explorer can reach it without you typing the network path every time. This guide covers mapping in File Explorer and with the net use command, keeping it connected at sign-in, handling credentials, a brief note on deploying drives by Group Policy, disconnecting, and fixing the errors people hit most.

Before you start

You need a folder that is already shared on the network and the name or IP address of the computer hosting it. If nothing is shared yet, set that up first with our guide to sharing files between Windows PCs. You will also need a user name and password valid on the sharing computer.

Sharing PC / NASshared folderYour Windows 11 PCZ: drive\\PC\Sharemapped over the networkAppears under This PC
A shared folder becomes a drive letter on your PC.

Method 1 — map a drive in File Explorer

  1. Open File Explorer and select This PC in the left pane.
  2. Click the three-dot (See more) menu on the toolbar and choose Map network drive.
  3. In Drive, pick any free letter (Windows suggests one, often Z:).
  4. In Folder, type the share path in UNC form — \\ComputerName\ShareName — or click Browse to find it under Network. You can use an IP address instead of a name, for example \\192.168.1.50\Files.
  5. Tick Reconnect at sign-in so the mapping returns after a restart.
  6. If the share needs a different account than your Windows sign-in, tick Connect using different credentials.
  7. Click Finish. Enter the user name and password if prompted, and optionally tick Remember my credentials.

The drive now shows under This PC with the letter you chose and opens like any local folder. Microsoft Support's Map a network drive in Windows article describes the same sequence — File Explorer → This PC, MoreMap network drive, pick any available drive letter, type the path in the Folder box, and select Reconnect at sign-in to connect every time you sign in.

Tip — a quick one-off without a drive letter

If you only need to reach a share once, you do not have to map it. Type the UNC path straight into the File Explorer address bar — for example \\DESKTOP-PC\Files — and press Enter to open it directly.

Method 2 — map a drive with net use

The net use command is faster once you know the path and is easy to drop into a script. Open Terminal or Command Prompt and run:

net use Z: \\ComputerName\ShareName /persistent:yes

Here Z: is the drive letter, the UNC path is the share, and /persistent:yes makes the mapping reconnect at every sign-in (the equivalent of the Reconnect at sign-in checkbox). Use /persistent:no for a mapping that lasts only until you sign out.

To supply a specific account, add the /user switch and let Windows prompt for the password:

net use Z: \\ComputerName\ShareName /user:ComputerName\username *

The * tells net use to ask for the password rather than putting it on the command line in plain text. To list every drive currently mapped, run net use with no arguments. Both behaviours are in the net use command reference on Microsoft Learn: type an asterisk to produce a prompt for the password, and used without parameters net use retrieves a list of network connections.

Persistence remembers your last choice

Windows remembers the last /persistent setting you used and applies it to later net use commands unless you state it again — Microsoft's reference puts it as "the default is the setting used last". If you care whether a mapping survives a reboot, include /persistent:yes or /persistent:no every time.

Reconnecting at sign-in and handling credentials

Reconnect at sign-in (or /persistent:yes) stores the mapping so it returns each time you log on. For that to work smoothly, Windows also needs valid credentials for the sharing computer. When you tick Remember my credentials, they are saved in Credential Manager, and the drive reconnects without asking again.

To view or clean up saved credentials, open Credential Manager (search for it, or Control Panel > User Accounts > Credential Manager) and look under Windows Credentials. From there you can edit or remove a stored entry — useful when a password changes and a mapped drive starts prompting or failing.

Drive shows connected but empty after reboot

A drive that reconnects before the network is fully up can appear with a red X until you open it. It usually connects on demand the moment you click into it. Persistent failures normally point to wrong or missing saved credentials, or the sharing PC being off or asleep.

Mapping drives with Group Policy (brief)

On a managed network, administrators do not map drives by hand on every PC. Instead they use Group Policy Preferences > Drive Maps (under User Configuration) to push a mapping to many machines at once, targeting who gets which drive. This is the standard approach in a business or school domain; for a single home PC it is not needed. If you administer a domain and want the full walk-through, our create a file share on Windows Server guide is the right starting point for the server side of the story.

Disconnecting a mapped drive

When you no longer need a mapping:

  • In File Explorer: open This PC, right-click the mapped drive and choose Disconnect.
  • With net use: remove one drive by letter —
    net use Z: /delete
    or remove every mapping at once with net use * /delete — the reference confirms that specifying the connection with an asterisk cancels all network connections.

Disconnecting only removes the drive letter on your PC; it does not touch the shared folder or its contents on the other computer.

Troubleshooting the common errors

  • "Windows cannot access \\PC\Share". Check the sharing computer is on and reachable — try ping by name or IP — and that the folder is actually shared. On the same network, a static IP on the host can make it easier to reach; see set a static IP in Windows 11.
  • Wrong user name or password. Map again with Connect using different credentials, or clear the stale entry in Credential Manager and re-enter it.
  • The network path was not found. Double-check the spelling of the computer name and share, and that both PCs are on the same network. If names do not resolve, try the host's IP address in the path, and see DNS server not responding.
  • The drive letter is already in use. Pick a different free letter, or disconnect the existing mapping on that letter first.

Frequently asked

What is a UNC path and how do I write one?

A UNC (Universal Naming Convention) path is how Windows names a shared folder on the network. It starts with two backslashes, then the computer name or IP address, then the share name, like \\DESKTOP-PC\Files. You can also use an IP address in place of the name, for example \\192.168.1.50\Files. That path is what you type into the Map network drive box or after a drive letter in net use.

Why does my mapped drive show a red X or fail to reconnect?

A red X usually means Windows has not reconnected the drive yet, not that it is broken. Open the drive and it often reconnects on demand. If it keeps failing, the sharing computer may be off or asleep, the stored credentials may be wrong, or the drive was mapped under different credentials than the ones you sign in with. Re-map it with the correct user name and password and tick Reconnect at sign-in.

How do I map a drive with a different user name and password?

In File Explorer's Map network drive dialog, tick Connect using different credentials before clicking Finish, then enter the account for the sharing computer. With net use, add the /user switch, for example net use Z: \\PC\Share /user:PC\username and you will be prompted for the password. You can save it so the drive reconnects without asking again.

Can I map a drive automatically for many PCs at once?

Yes. In a Windows domain, administrators deploy mapped drives to many machines with Group Policy Preferences under User Configuration, so users get the drive without setting it up by hand. For a single home PC, mapping in File Explorer or with net use and choosing Reconnect at sign-in is all you need.

More Windows help

Browse all networking guides for more current, step-by-step Windows 11 walk-throughs, or explore the windows-now.com archive of restored community posts from the original site.