Type the following command to map a drive providing authentication details and press Enter: net use Z: \\DEVICE-NAME-OR-IP\SHARED-FOLDER PASSWORD /user:USERNAME /persistent:yes Then replace DEVICE-NAME-OR-IP and SHARED-FOLDER for the computer name or IP address of the device hosting the shared folder and the name of the shared.įor example, this command maps the ShareOne folder to the computer: net use * \\vm-beta\ShareOne In the command, the (*) is the option that allows the system to assign any drive letter that is not already in use. Type the following command to map a drive assigning drive letter automatically and press Enter: net use * \\DEVICE-NAME-OR-IP\SHARED-FOLDER Then replace DEVICE-NAME-OR-IP and SHARED-FOLDER for the computer name or IP address of the device hosting the shared folder and the name of the shared.įor example, this command maps the ShareOne folder to the computer with the “Z” drive letter: net use Z: \\vm-beta\ShareOne In the command, replace “Z” with the drive letter not already in use you want to use.
Type the following command to map a drive assigning drive letter manually and press Enter: net use Z: \\DEVICE-NAME-OR-IP\SHARED-FOLDER
As a result, make sure to run the command as a standard user. Quick note: If you run the command as an administrator, the drive may not mount correctly and won’t appear in File Explorer. Search for Command Prompt and click the top result to open the console. To use the net command to map a shared folder as a drive, use these steps:
#Dos commands windows 10 windows 10#
Map network drive on Windows 10 with Command Prompt Disconnect mapped network drive on Windows 10 with Command Prompt.Map network drive on Windows 10 with Command Prompt.
#Dos commands windows 10 how to#
In this guide, you will learn the steps to use Command Prompt to map a network drive on Windows 10 and how to disconnect when you no longer need access to the shared folder. Once a drive is mapped, it will appear on “This PC,” under “Network locations,” for quick access to files stored on another computer from File Explorer. When connecting to a network drive, Windows 10 is essentially creating a “shortcut” that points to the shared folder with a drive letter and the username and password to access its content. On Windows 10, you can quickly map a network drive in several ways, including using Command Prompt when you prefer to use command lines or creating a script to access files stored on another computer.