dos change drive letter assignments

Contribute to the Windows forum! Click  here  to learn more  💡

April 9, 2024

Contribute to the Windows forum!

Click  here  to learn more  💡

Windows 11 Top Forum Contributors: neilpzz  -  RAJU.MSC.MATHEMATICS  -  Kapil Arya MVP  -  Ramesh Srinivasan  -  _AW_ 👍✅

April 17, 2024

Windows 11 Top Forum Contributors:

neilpzz  -  RAJU.MSC.MATHEMATICS  -  Kapil Arya MVP  -  Ramesh Srinivasan  -  _AW_ 👍✅

  • Search the community and support articles
  • Search Community member

Ask a new question

LightJack05

  • Article Author

Manually assigning a drive letter using CMD/Diskpart

[Localization from this article: Manuelles Zuweisen eines Laufwerksbuchstaben mit CMD bzw. Diskpart - Microsoft Community ]

Technical Difficulty: Expert

Applies to: Windows 10 & 11

In some cases, Windows will not assign a drive letter automatically to an inserted drive. For example, this can happen when using a Windows installation media.

In that case, you can use diskpart to manually assign a drive letter.

NOTE: If your drive doesn't get assigned a drive letter, even though you are in a normal Windows environment, this can indicate a problem with the drive. Please back up your files in that case.

Open up a command prompt (CMD/PowerShell).

Type "diskpart" to start up diskpart. You will see the prompt change to "DISKPART>".

dos change drive letter assignments

Type "list vol" to list all available volumes. You can identify the drive by size and file system.

Additionally, the volume doesn't currently have a drive letter.

dos change drive letter assignments

Select the volume using "sel vol <number>".

dos change drive letter assignments

Assign the drive letter using "assign letter=<letter>".

dos change drive letter assignments

You can now exit diskpart by typing "exit" and switch to the drive using "<letter>:".

dos change drive letter assignments

It should also be available from Windows Explorer now.

58 people found this helpful

  • Subscribe to RSS feed

Was this article helpful? Yes No

Sorry this didn't help.

Great! Thanks for your feedback.

How satisfied are you with this article?

Thanks for your feedback, it helps us improve the site.

Thanks for your feedback.

Comments (17) 

* Please try a lower page number.

* Please enter only numbers.

Joe13 B-) 2.0

Thanks for the tutorial, I don't think I need to use Google for it anymore!

Congrats on Article Author too! :)

Report abuse

Reported content has been submitted​

6 people found this comment helpful

Was this comment helpful? Yes No

How satisfied are you with this comment?

Thanks for the tutorial, I don't think I need to use Google for it anymore! Congrats on Article Author too! :)

5 people found this comment helpful

Thanks! Happy I could help! :)

1 person found this comment helpful

RAJU.MSC.MATHEMATICS

Very helpful Thanks.

3 people found this comment helpful

Thank for this informative article.

I ran this in PowerShell PS C:\WINDOWS\system32> GWMI -namespace root\cimv2 -class win32_volume | FL -property DriveLetter, DeviceID

The results are below. I need to know more about the DriveLetter, that does not have a letter and I cannot give it a letter, as you can see in DiskPart.

I'm sure someone personally hacking my computer. I'm wondering if this them hiding on it, and that is why I someone is typing over me and has more control at times of my computer then I do. Maybe a hidden AD Hoc.

I have searched for this on Google I'm either getting blocked or there is no information out there on this.

PS C:\WINDOWS\system32> GWMI -namespace root\cimv2 -class win32_volume | FL -property DriveLetter, DeviceID

DriveLetter : B:

DeviceID : \\?\Volume{26xxxxxx--xxxx-xxxx-xxxxxxxxxxxxxx}\

DriveLetter : C:

DriveLetter :

DeviceID : \\?\Volume{d5xxxxxx--xxxx-xxxx-xxxxxxxxxxxxxx}\

DriveLetter : D:

PS C:\WINDOWS\system32> DiskPart

Microsoft DiskPart version 10.0.19041.1

Copyright (C) Microsoft Corporation.

On computer: My Computer

DISKPART> List Volume

Volume ### Ltr Label Fs Type Size Status Info

---------- --- --- -------- ----- ---------- ------- --------- --------

Volume 0 D RAW DVD-ROM 2048 B Healthy

Volume 1 B System Rese NTFS Partition 100 MB Healthy System

Volume 2 C NTFS Partition 698 GB Healthy Boot

2 people found this comment helpful

I followed the instructions to CHANGE the letters assigned for three external hard drives. (The computer had named them E, F, G but gave the names to the wrong external hard drive) I changed the letters to the correct names singly (I disconnected the two not being adjusted) Now, I have 2 E, 2 F, 2 G names in the list (when accessed through File Explorer. When I click on "This PC", it shows just the one of each. If I click on either, or both of the same letter name, the same exact files will open. This is annoying. Anyone have a clue what can be done? This is on a brand new computer running Windows 11.

Sorry about the late reply.

That sounds weird... Usually, windows doesn't allow you to assign a drive letter twice.

If you want to change the letters, you usually have to remove them first and then reassign them.

Can you send me a screenshot of disk management, and of the list of volumes?

the partition that is not shown in diskpart is most likely some sort of recovery or reserved partition.

This is not the typical way of hiding an infection with malware...

Also, do note that your ESP (Volume B) should not be mounted, since modifying it can corrupt your Bootloader.

As for the suspected hacking, what symptoms did you observe? Mouse moving on its own, high resource usage, unexpected firewall prompts? Other things?

If you have a compromised system, its almost impossible to clean it from infections without doing a clean install of windows. I would suggest you do that if you suspect an infection. It will take time though and will delete everything on your PC. (Including files, programs, settings.) Create a backup before you reinstall.

There are no viruses nor malware on this computer. I believe it is a reflection of the original name choice. The information contained on each external hard drive is identical, yet when I go into MY PC, it only shows one set of externals. I am afraid to delete one of the duplicates because it might be just mirrored and it will make everything go away. I have way too many things on these external hard drives to lose any of them.

Thanks for your input. Jan

Forum Article Info

  • Devices and drivers
  • Norsk Bokmål
  • Ελληνικά
  • Русский
  • עברית
  • العربية
  • ไทย
  • 한국어
  • 中文(简体)
  • 中文(繁體)
  • 日本語
  • Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Quick Links

  • Recent Discussions
  • 10.1K All Categories
  • 365 News & Announcements
  • 102 Software Spotlights
  • 740 Site Issues
  • 3.6K Offers & Requests
  • 772 Product Comments
  • 1.1K Hardware
  • 3.2K Software
  • 100 Video Games
  • 57 Programming

Changing drive letters in MS-DOS 6.22?

Twiggy

BigCJ wrote: Add this line to CONFIG.SYS LASTDRIVE=Z This makes all drive letters assignable. The CD-ROM should be receive a drive letter now.
BigCJ wrote: That isn't really possible AFAIK. Changing drive letters wasn't easy until Windows came along. I'd backup the data and repartition the Logical drives.
BigCJ wrote: Wait, what exactly are you trying to do? Have primary partition as C:, the CD-ROM as and then the Logical drives? It's supposed to list the hard disks and their partitions before CD drives.
BigCJ wrote: That isn't possible under DOS. See, MSCDEX presents the CD-ROM drive to DOS as a network drive, and those load after hard disks and their partitions. What's wrong with your CD drive having a higher drive letter?
BigCJ wrote: Having the CD drive(s) after the hard disk partitions *was* standard way back when. The "CD drive being no matter what" ideal came about in the Win9x-era.

Sandpit

MiniTool

How to Change Drive Letter with CMD Windows 10

Diskpart is a command-line tool in Windows system that allows you to manage your disks and partitions. This post introduces how to change drive letter with CMD in Windows 10, namely, by using Diskpart CMD tool. MiniTool software provides users a free disk partition manager, data recovery software, system backup and restore software, etc.

If you want, you can change drive letter for a drive with CMD (Command Prompt) in Windows 10. This post includes detailed guides for how to use Diskpart command-line tool to change driver letter in CMD.

How to Change Drive Letter with CMD in Windows 10

Diskpart is a Windows built-in CMD tool that lets you easily manage hard drive and change drive letter. To change or assign drive letter in CMD, you can firstly open Diskpart utility in Command Prompt. Check the steps below.

Step 1. Open CMD in Windows 10

You can press Windows + R , type cmd , and press Ctrl + Shift + Enter to open elevated Command Prompt .

Step 2. Open Diskpart tool

In Command Prompt window, you can type diskpart command, and press Enter . This will open the Diskpart command-line utility.

Step 3. Change drive letter CMD

Next you can type the command line below to change drive letter in Command Prompt in Windows 10. Remember to press Enter after typing each command line.

  • list volume (this command will list all available volumes detected by your computer)
  • select volume * (replace “*” with the exact volume number of the target partition)
  • assign letter=* (replace “*” with the preferred drive letter like “F”)

Windows change drive letter

After you change or assign a drive letter for a drive or device, Windows will display the same letter automatically next time you reconnect the device to your computer.

If you want to remove the drive letter of a specific drive, you can type remove letter=* command and press Enter . Still, replace “*” with the exact drive letter of the target drive.

How to Change Drive Letter Using PowerShell

Some Windows 10 users might find that Command Prompt is missing from Win + X menu , and instead, it shows Windows PowerShell. Windows PowerShell can do most things that Command Prompt does. Alternatively, you can also use Windows PowerShell to change drive letter in Windows 10.

Step 1. Press Windows + X , and choose Windows PowerShell (Admin) to run Windows PowerShell utility as administrator.

Step 2. Next type get-disk command and press Enter to list all available drives the computer detected.

Step 3. Then you can type the command: Get-Partition -DiskNumber 1 | Set-Partition -NewDriveLetter F , and press Enter to assign a new drive letter. You should change “*” with the actual disk number of target drive, and replace “F” with the new drive letter you’d like to assign to the drive.

change drive letter PowerShell

MiniTool Partition Wizard – Professional Free Disk Partition Manager

Instead of using CMD or PowerShell to change drive letter for a drive in Windows 10, you can also utilize third-party free disk partition manager like MiniTool Partition Wizard to easily change drive letter and manage disk partitions on Windows 10.

MiniTool Partition Wizard let you easily create/delete/extend/resize/format/wipe partitions, convert partitions formats, migrate OS, clone disk, test hard drive speed , analyze hard drive space usage, check and fix disk errors , and more.

change drive letter with MiniTool Partition Wizard

By following the detailed guides above, you can easily change drive letter with CMD (Command Prompt), PowerShell or MiniTool Partitioon Wizard on Windows 10.

About The Author

Position: Columnist

How-To Geek

How to change a drive letter on windows 10 or windows 11.

You can change your drive letters in Windows 10 and 11 using the Disk Management utility.

Quick Links

What changing a drive letter does, how to change a drive letter, how to fix programs broken by changing a drive letter.

Changing the letter of a drive is easy on Windows 10 and Windows 11, but you should do it as soon as you add the drive to prevent future hassles. Find out how to change a drive letter here.

Windows assigns drive letters alphabetically --- starting with C --- when they're initialized. If you want to change a drive letter, you should do it before you install anything on the drive. Changing a drive letter after programs are installed could break them since there will be references to an installation location that is no longer there.

Windows has gotten pretty smart about updating shortcuts so that programs work after changing a drive letter. Most of your applications' shortcuts will probably be automatically corrected. Unfortunately, Windows isn't as good about updating file associations. You'll have to manually set the default apps associated with files to fix file associations if they were broken by changing the drive letter.

It is possible to change the boot drive letter to something else, but we don't recommend it. Changing C:\ to another letter is likely to result in severe issues, like a PC that cannot boot into Windows at all. Even if it were able to boot, there would be a huge number of programs that would not be able to run.

Technically speaking, while they are commonly called drive letters, each letter actually refers to a partition on a disk. If you have multiple partitions on a single disk, you will need to assign a letter to each partition to make them all accessible. If a disk has just a single partition, it will just have a single letter pointing to that partition. (However, you do not have to assign a letter to each partition. Partitions without drive letters will not appear in File Explorer and elsewhere.)

Changing a drive letter is pretty simple. Click the Start button, type "Disk Management" in the search bar, and then hit Enter.

The program name displayed in the search will not be Disk Management. It will be "Create and format hard disk partitions."

You could also hit Windows+X or right-click the Start button, and then click "Disk Management."

Identify the drive you'd like to change in the Disk Management Window. In this example, we'll change the letter of the D:\ drive to J:\. You can right-click the drive on the text list, or on the menu below. Either works.

Select "Change Drive Letter and Paths" in the right-click menu that appears.

In the window that pops up, click "Change."

Select whatever letter you want from the drop-down menu. Then click "Ok."

Two popups will warn you about changing your drive letter. Click "Yes" on both of them, and then restart your computer.

Once Windows has restarted, the drive letter should be changed.

There are a few ways you can fix a program broken by changing the drive letter.

Fix The Shortcut

If you're lucky, the only thing that is broken is the shortcut. Fix a shortcut by right-clicking the shortcut on your desktop, and then click Properties.

You need to change the target of the shortcut to the new drive letter.

For example, if GIMP was previously installed at " D :\GIMP 2\bin\gimp-2.10.exe," and you changed the D drive to J, change the target of the shortcut to " J :\GIMP 2\bin\gimp-2.10.exe."

Finalize the change by clicking "Apply" and then "Ok."

Reinstall the Program

Reinstalling the program will generate new entries in the registry, so everything on the computer will know where to look for the program. Some installers won't like reinstalling directly over existing files, so you may need to rename or delete the old installation first.

Change the Drive Letter Back

If you changed the drive letter of a drive with a lot of programs installed, it might be easier to change the drive letter back. Changing the drive letter back should automatically fix any programs and file associations that were broken.

Edit the Registry

You can break programs, or even Windows itself, by editing the registry. Be careful, and learn about how to edit the registry before you try it. Make sure you backup the Windows registry first. You should not attempt this method unless you have no other options.

Windows, and a lot of programs, track where programs are installed via the Windows registry. It is possible to manually adjust the registry to fix broken programs. Keep in mind that there could be dozens of registry entries you need to edit. A program like GIMP can have registry entries for the context menu, for the "Open With" menu, for any file associations, and for the location of its executables. Other programs may only have a few entries related to where it is installed.

If you're not deterred, here's how you do it.

First, you need to know where the program was previously installed. In this case, the program was installed to the "D:\GIMP 2" folder, and the executables were found the "D:\GIMP 2\bin" sub-folder. It is now located at "J:\GIMP 2" instead.

We need to update the registry to reflect the change in location. Click the Start button, type "regedit" into the search bar, right-click Regedit, and click "Run as administrator."

In Regedit, hit Ctrl+F to bring up a search window. Type in the old location for the program you're trying to fix --- "D:\GIMP 2" for our example --- then click "Find Next."

Once Regedit has found something with "D:\GIMP 2" as part of a path, it'll show it to you. Here is an example from the GIMP search.

To actually change them, double click the name of the registry entry you want to modify. Then change the drive letter to J, or whatever you chose. If you didn't otherwise move the folder, leave the rest of the path alone. Then click "Ok."

You'll need to repeat this multiple times. To find the next result using your search term, you can hit the F3 key. There will be a popup once you've found all of the entries.

Changing drive letters can be a simple way to customize your PC. Do it before you install anything on the drive, however. You'll prevent any problems before they occur, and probably save yourself quite a bit of troubleshooting.

How to assign permanent letters to drives on Windows 10

You can assign drive letters manually, and in this guide, we show you how on Windows 10.

dos change drive letter assignments

On Windows 10, when connecting a removable storage device or an internal hard drive, the system detects and assigns a drive letter automatically to make it usable. However, when reconnecting an external drive (such as a USB flash drive or SD or microSD cards), the system can end up assigning a different letter, which can be annoying.

If you want to see the same drive letter on a particular device, you can manually assign a permanent letter to any drive connected to your computer, and on Windows 10 , you can do this in at least three different ways, using Disk Management, Command Prompt, or PowerShell.

Using this approach will prevent Windows 10 from assigning a new letter or trying to set a letter already in use, which can cause conflicts. Also, it helps to select a drive letter that makes more sense to you.

In this Windows 10 guide, we walk you through several methods to manually assign a permanent letter to a drive, as long as you're connecting the drive to the same device and the letter isn't already in use.

How to assign a drive letter using Disk Management

How to assign a drive letter using command prompt, how to assign a drive letter using powershell.

To manage drive letters with the Disk Management tool, use these steps:

  • Open Start .
  • Search for Create and format hard disk partitions and click the top result to open the Disk Management experience.
  • Right-click the drive and select the Change Drive Letter and Paths option.

dos change drive letter assignments

  • Click the Change button.

dos change drive letter assignments

  • Select the Assign the following drive letter option.
  • Use the drop-down menu to assign a new drive letter. Quick tip: To avoid the system trying to assign the same letter to another drive, it's a good idea to start adding letters in backward order. For instance, instead of using D, E or F, it better to start with Z, Y or X when assigning a new letter.

dos change drive letter assignments

  • Click the OK button.
  • Click the OK button again.

Once you complete these steps, the drive will permanently retain the assigned letter, even after reconnecting it. However, if you connect the drive to another device, it may receive a different letter.

While the easiest way to assign a new drive letter is to use Disk Management, you can also use DiskPart in Command Prompt to perform the same task.

Get the Windows Central Newsletter

All the latest news, reviews, and guides for Windows and Xbox diehards.

To assign a drive letter using Command Prompt, use these steps:

  • Search for Command Prompt , right-click the result, and then select the Run as administrator option.
  • Type the following command to start DiskPart and press Enter : diskpart
  • Type the following command to list all the available volumes and press Enter : list volume
  • Type the following command to select the volume (drive) to assign a new letter and press Enter: select volume 3 In the command, make sure to change "3" to the number that represents the drive on your device.
  • Type the following command to assign a new drive letter, and press Enter : assign letter=Z The command assigns the letter "Z" to the drive assuming it's available. However, you need to make sure to change the letter for the one that you want to use.

dos change drive letter assignments

After completing these steps, similar to Disk Management, every time you reconnect the storage to the same device, Windows 10 should assign the same letter automatically.

Alternatively, you can also use PowerShell to change a drive letter on Windows 10 using these steps:

  • Search for PowerShell , right-click the result, and then select the Run as administrator option.
  • Type the following command to list the available drives and press Enter : Get-Disk
  • Type the following command to assign a permanent letter to the drive and press Enter : Get-Partition -DiskNumber 1 | Set-Partition -NewDriveLetter Z In the command, make sure to change "1" to the number that represents the drive that you want to modify, and change "Z" for the new letter that you want to use.

dos change drive letter assignments

Once you complete the steps, the drive will be accessible through File Explorer using the letter that you assigned, and Windows 10 won't try to change it.

Updated March 7, 2019: We revised this guide to make sure it's current with the latest version of Windows 10.

More Windows 10 resources

For more helpful articles, coverage, and answers to common questions about Windows 10, visit the following resources:

  • Windows 10 on Windows Central – All you need to know
  • Windows 10 help, tips, and tricks
  • Windows 10 forums on Windows Central

Mauro Huculak

Mauro Huculak is technical writer for WindowsCentral.com. His primary focus is to write comprehensive how-tos to help users get the most out of Windows 10 and its many related technologies. He has an IT background with professional certifications from Microsoft, Cisco, and CompTIA, and he's a recognized member of the Microsoft MVP community.

  • 2 Microsoft CEO Satya Nadella says "Security underpins every layer of the tech stack and it's our No. 1 priority. We are doubling down on this very important work" amid rising concerns over 'cascade of security failures'
  • 3 The Division 2 Year 6: Expected start date, roadmap, DLC, and everything we know so far
  • 4 I review tons of laptops, and I've never seen one handle intensive graphics this well before — it's incredibly powerful
  • 5 This ultraportable AI laptop wants to travel with you, and it's got insane battery life to do it

dos change drive letter assignments

Computer Hope

How to change a drive letter

Microsoft Windows logo

In Microsoft Windows, different storage media , devices, and partitions on your computer are identified using drive letters . By default, these letters are assigned automatically. However, if you desire to change a default drive letter, may do so by following the steps below.

If you're trying to switch between drives, see: How to change drives in MS-DOS and Windows command line.

Windows 2000, XP, Vista, 7, 8, 10, and 11

  • CD-ROM, DVD-ROM, and other devices.
  • Open the Disk Management utility .
  • Right-click the volume whose drive letter you want to change and select the Change Drive Letter and Paths option.

Menu for changing a drive letter in Windows

  • In the window, click the Change button.

Menu for changing drive letters

  • In the next window, select the letter you desire from the drop-down menu on the right, then click OK .

Change drive letter window

CD-ROM, DVD-ROM, and other devices

In the newer versions of Windows, devices that are not considered to be volumes (i.e., CD-ROM (compact disc read-only memory) and DVD-ROM (digital versatile disc read-only memory) drives) aren't listed on the same page as hard drives , SSDs , and partitions . However, you can adjust which section you are viewing, allowing you to assign a different drive letter to these devices.

The letter you assign to these devices must come after that of the hard drive. For example, because your hard drive is C:, you may only use D: through Z:. If you have multiple hard drives or partitions and your last drive letter is F:, you can only change your device's drive letter to G: through Z:.

  • Windows 2000, XP, Vista, 7, 8, 10, and 11.
  • Windows 95, Windows 98, and Windows Me.
  • MS-DOS and Windows 3.X.
  • At the top of Disk Management window, click the View menu.
  • In the drop-down menu , select Top , then select Disk List .

Disk list menu in Windows, showing disk drives

  • Right-click the disk drive whose drive letter you want to change and select the Change Drive Letter and Paths option.

Menu for changing a disk drive letter in Windows.

Windows 95, Windows 98, and Windows Me

  • Open the Device Manager .
  • Click the plus sign (+) next to CD-ROM or DVD/CD-ROM drives .
  • Double-click the disk drive whose drive letter you want to change.
  • Click the Settings tab.
  • Where the computer lists the Start and end drive letter , make your selection and click OK .
  • Restart the computer.
  • How to restart Microsoft Windows.

MS-DOS and Windows 3.X

  • If you are in Windows, Exit to an MS-DOS prompt .
  • Type cd\ and press Enter .
  • Once at DOS type edit c:\autoexec.bat
  • In the autoexec.bat window, locate the MSCDEX line .
  • On the MSCDEX line, if it's missing /L:x (where x is the drive letter), add /L:D (assigning the CD-ROM to D: and can be anything up to Z:).
  • Once changes are made, click File (if you do not have a mouse, press Alt + F ), then choose Exit and say Yes to save the changes .
  • Once back at DOS, type edit c:\config.sys
  • In the config.sys window, look for anything that says "LASTDRIVE=x" (were x is the last drive letter). If the line is missing, add LASTDRIVE=K (or the letter you want as the ending letter) at the top of the config.sys file.

The LASTDRIVE must be a letter between C and Z.

  • Once changes are made, click File (if you do not have a mouse , press Alt + F ), then choose Exit and say Yes to save the changes .

Related information

  • How to rename or label a disk drive.
  • How to set up a hard drive and partition in Windows.
  • How to merge partitions in Windows.
  • How to delete a partition in Windows.
  • See the hard drive and Windows definitions for related information and links.

Sign up for our daily newsletter

  • Privacy Policy
  • Advertise with Us

6 Ways to Change the Drive Letter in Windows

Ojash Yadav

If your PC suddenly stops showing one of your internal drives in the file explorer or not list your external drive, it could be due to the OS getting confused with the drive letters. Simply changing your assigned drive letters can help you bypass this conflict. Here are six ways to change the drive letter.

1. Change the Drive Letter Using Settings

2. using command prompt, 3. disk management, 4. registry editor, 5. windows powershell, 6. drive letter changer software, frequently asked questions.

Also read: How to Clean Up and Make Space on Your Windows “C” Drive

Is It Safe to Change a Drive Letter in Windows?

Changing the drive letter is not entirely harmless and can cause significant problems based on the contents of your drive. If you have applications and software installed on your drive, those applications may cease to work.

For example, if you change the name of your D: drive to an F: drive, then the software installed in the D drive will still search for code in the D: file. While you can still access the data inside, there may be errors that will cause a nuisance in your day-to-day usage.

However, you may safely change the letter of some drives. If a partition simply includes data files that you rarely use, changing the drive letter may cause minor inconvenience, but nothing serious. The letters of external drives can almost always be changed without any problems.

  • Press Win + I to open the Settings app, then select the “System” tab. Scroll down and click on “Storage.”

Windows 11 Settings Storage Section

  • Scroll down on the right side and click on “Advanced storage settings.”

Advanced Storage Options

  • Under Advanced storage settings, click on “Disks & Volumes.”

Disk Volumes

  • Select the drive whose letter you want to change, then click on the “Properties” button for that drive.

Disk Volumes Properties

  • In the Drive Properties, you will find the option to change the drive letter of the selected drive.

Disk Volumes Change Drive Letter

  • Once you click on the option to change the drive letter, you will find a drop-down menu that will allow you to change the drive letter.

Choose Drive Letter

  • Click on the letter you want to assign.

Volume Data Drive Letter

  • Once you have selected your preferred letter, click on “OK” to confirm your choice.

System Change Drive Letter

Also read: How to Format a Drive in FAT32 in Windows

  • Search for the command prompt on the start menu by typing cmd , right-click on it, and select “Run as administrator”.

Search For Cmd

  • On the command prompt home screen, type:

Diskpart Utility Homescreen

  • Press Enter , then type:

List Volume

  • Press Enter. You’ll see a list of your system’s drives. Make a note of the volume number of the drive. In the example pictured, it’s “Volume 3”.

Cmd Select Volume

  • Type the following code:
  • Type the following code to assign the new letter:

Instead of “new drive letter,” type the letter you want. For example: assign letter=S

Diskpart Drive Letter Assigned

The drive letter will be changed to your preferred letter.

Also read: 8 Ways to Customize Windows Terminal

  • Right-click on the Windows button and open “Disk Management.”

Open Disk Management Utility

  • Under the “Volume” column, you will find the various partitions of your storage. You need to find the drive whose letter you’ll change and right-click on it.

Disk Management Select Drive

  • In the dialog box that appears, click on “Change.”

Change Drive Letter Button

  • Click the drop-down menu next to “Assign the following drive letter,” then select your letter and press “OK.”

Disk Management Select A New Drive Letter

  • A warning message will pop up. Click “Yes” if you are sure about your decision to change the drive letter.

Disk Management Apply Changes

Also read: Which Allocation Unit Size Is Best for Your Drive?

  • To change the drive letter through registry editor, first press Win + R to open the Run dialog and type regedit .

Search For Registry Editor

  • Type in the following address at the top of the application:

and press Enter .

Registry Editor Mounted Devices

  • Navigate to the list of binary keys. Select the key that corresponds to the drive letter that you want to change. For example, if we want to change the letter of the D: drive, we would look for “\DosDevices\D:”
  • Right-click on the selected registry and rename the drive letter to what you want, just as you would rename any other file.You will have to restart your computer for the effects to take place.

Registry Editor Rename

Also read: 16 Useful Windows Registry Hacks to Optimize Your Experience

  • Using the search button on the taskbar, search for “Powershell” and run it as administrator.

Windows Powershell

  • Type the following command:

Powershell Get Partition Command

  • A screen will show you your disk partitions. Make a note of what drive letter you want to change.

Administrator Windows Powershell Listing Drives

  • To change the drive letter, type the following command:

Make sure to substitute “current drive letter’ and “new drive letter” with the actual drive letters, then press Enter .

Windows Powershell Settings New Drive Letter

Also read: How to Map a WebDAV Drive in Windows

If you are looking for a tool that can help you manage your partition and drives, these software will help you change your drive letter.

  • MiniTool Partition Wizard
  • AOMEI Partition Assistant
  • EaseUS Partition Master

These tools are easy to use and have GUI interfaces that make them simple to use and also a one-stop destination for you to manage your storage devices. For the purposes of the demonstration, we are using MiniTool Partition Wizard to change the drive letter.

  • Download MiniTool Partition Wizard. (It is a direct download link.)

Minitools Installer

  • Run the installer and launch the app. You will get a listing of all your drive partitions mentioned below.

Minitool Partition Wizard Homescreen

  • Right-click on the target drive partition and select “Change Letter.”

Minitools Change Letter

  • Open the drop-down list and select a new drive letter for your target drive.

Se;ect A New Drive Letter In Minitool

  • Click on “Apply” to save the changes.

Minitool Click Apply

  • You will receive a warning pop-up asking you to close all background applications. Click “Yes.”

Minitool Apply Changes Warning

  • You will now receive a confirmation message telling you that the new changes have been applied.Click “OK.”

Minitool Changes Applied Dialouge Box

Also read: How to Format Your USB Drives in Windows

1. How are drive letters assigned in Windows?

Drive letters are assigned to every new drive in alphabetical order. Traditionally, the A: and B: drives were used for floppy disks, and the system drive on which Windows is installed is named C: by default.

2. Can I change the drive letter for the System Drive?

No, changing the drive letter on the system drive is not possible, as Windows is installed on the system drive. If that was changed, the system drive would not be found and the computer would cease working.

3. Can I switch drive letters among two drives?

No, there is no functionality in Windows to switch drive letters directly between two drives. If you want to switch the drive letters between the D: drive and the E: drive, you will have first change the D: drive to another letter (so as to free up the D:), change the E: to D:, then change the first one to E:.

Image credit: Plastic magnetic letters by 123RF

Our latest tutorials delivered straight to your inbox

Ojash Yadav

Ojash has been writing about tech back since Symbian-based Nokia was the closest thing to a smartphone. He spends most of his time writing, researching, or ranting about Bitcoin. Ojash also contributes to other popular sites like MakeUseOf, SlashGear, and MacBookJournal.

Best Windows Download Managers Featured 2

Stack Exchange Network

Stack Exchange network consists of 183 Q&A communities including Stack Overflow , the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Q&A for work

Connect and share knowledge within a single location that is structured and easy to search.

Can I rearrange drive letters of my mapped network drives?

I have several network storage drives that I've mapped in Windows. I'm wondering if I can change their assigned drive letters easily rather than disconnecting from them all and remapping in my preferred order.

  • network-shares
  • drive-letter

intA's user avatar

  • 1 You don't have to do them in a certain order. When you map the drive you can assign the drive letter at that point. –  Ramhound May 18, 2015 at 17:24
  • I think you can rename them, and you can re-assign drive letters in Disk Management, but they need to be disconnected to do so. –  TheWanderer May 18, 2015 at 17:25
  • @Zacharee1, I don't think you can manage network drives like this in Disk Management. I do not see any of them listed there, and disconnecting the drives would mean essentially getting rid of that mapping. When I right click a network drive and select 'disconnect' the drive dissapears for good. –  intA May 18, 2015 at 20:05
  • Like I said, there's no way to rename them, thanks to the way Windows works. I realized the Disk Management problem right after I posted it. –  TheWanderer May 18, 2015 at 20:06
  • It's not such a big chore: when you disconnect a network drive, the path remains in the drop-down list when you set up a new mapping, so it's only half a dozen clicks per drive. –  AFH May 18, 2015 at 21:50

2 Answers 2

Start → Run.. . (or just press Win + R )

Type: "regedit"

Navigate to HKEY_CURRENT_USER\Network\

There you will see a list of letters representing your mapped network drives.

Right-click the one you want to change and select "Rename". Type your desired new drive letter and close RegEdit.

Your network drive is now associated with the new drive letter.

Andreas's user avatar

  • Brilliant! Thanks for this –  Chris Browet Aug 16, 2019 at 16:52
  • Reboot was even not needed on my Windows 10 2004 –  cid Jan 6, 2021 at 10:31
  • 1 In order to not reboot, one may restart explorer.exe (the most casual way would be to have an Explorer window open, go to Task Manager - Processes tab, right-click Windows Explorer app, click Restart ). This will mount under newly renamed letter, but old mounts will persist until reboot or manual disconnect (e.g. via right click menu) –  Leeroy Mar 8, 2022 at 11:57

In Windows Explorer, go to "This PC" and click "Map network drive".

enter image description here

Now you can choose the network folder and change the drive letter. No reboot required.

enter image description here

You must log in to answer this question.

Not the answer you're looking for browse other questions tagged windows network-shares drive-letter ..

  • The Overflow Blog
  • Net neutrality is in; TikTok and noncompetes are out
  • Upcoming research at Stack Overflow
  • Featured on Meta
  • Testing a new version of Stack Overflow Jobs

Hot Network Questions

  • Identify Notation, dot (period or point) with semicircle below
  • Copying and pasting letters of recommendation
  • What is the DC of a Long Jump?
  • What is "What *is*."?
  • Does Sidorenko's conjecture hold when the host graph's maxdegree/mindegree is a constant?
  • Why doesn't Singapore stamp passports?
  • Are there written historical records of ships possibly affected by underwater volcanic activity?
  • How quickly can a percussionist switch from vibraphone to marimba?
  • How do you validate the credibility of arXiv cited papers in IEEE conferences?
  • How does mass relate to kinetic energy?
  • What does this concatenation operator do?
  • Can my step dad steal from my room when I’m gone
  • Can facio be used to express visiting someone?
  • Having a second bite of the data-apple without p-hacking
  • Is 造れる intransitive form for 造る?
  • Should copper tubes be sealed when removing aircons?
  • What would be the color of this ammonia ocean?
  • Shade a specific area
  • How can I have a non-elevated script execute another specific script as root without requiring a password from the user?
  • How can I find where a short has occurred inside of a PCB?
  • Is there a way to slow down an SSD trim so it doesn't affect the drive's read performance while it is in progress?
  • Does consumer protection cover price changes at point of sale?
  • jacking up a car on "grass paving block" - how to secure jack and supports?
  • What is this 4-pin fan header?

dos change drive letter assignments

  • Is Hulu Worth It?
  • iPad Pro vs. Surface Pro: What's the Difference?

How to Change a Drive Letter

Don't like the letters assigned to your drives in Windows? Change them!

dos change drive letter assignments

  • Emporia State University

dos change drive letter assignments

  • The Ultimate Laptop Buying Guide

What to Know

  • Open Disk Management. Locate the drive you want to change. Right-click and choose Change Drive Letter and Paths > Change .
  • Select the drive letter you want to assign from Assign the following drive letter . Then select OK and choose Yes .

The letters assigned to your hard drives, optical drives, and USB drives in Windows are not fixed. Use the Disk Management tool in Windows to change drive letters. These steps apply to Windows XP and newer versions of Windows .

How to Change Drive Letters in Windows

Follow these steps to change the driver letters in any version of Windows.

You can't change the drive letter of the partition that Windows is installed onto. On most computers, this is usually the C drive.

Open Disk Management , the tool in Windows that lets you manage drive letters, among [many] other things.

In Windows 11/10/8, Disk Management is also available from the Power User Menu ( WIN + X  keyboard shortcut) and is probably the quickest way to open it. You can also start Disk Management from the Command Prompt in any version of Windows, but starting it via Computer Management is probably best for most of you.

Locate from the list at the top, or from the map at the bottom, the drive you want to change the drive letter of.

If you're not sure that the drive you're looking at is really the one you want to change the drive letter for, you can right-click or tap-and-hold the drive and then choose Explore . If you need to, look through the folders to see if that's the right drive.

Right-click or tap-and-hold the drive and choose Change Drive Letter and Paths .

Select Change .

If you've selected the primary drive by accident, some versions of Windows will display a message that reads Windows cannot modify the drive letter of your system volume or boot volume.

Choose the drive letter you want Windows to assign to this storage device by selecting it from the Assign the following drive letter drop-down box.

You don't need to worry if the drive letter is already being used by another drive because Windows hides any letters you can't use.

Select OK .

Choose Yes to the Some programs that rely on drive letters might not run correctly. Do you want to continue? question.

If you have software installed to this drive, it might stop working properly after changing the drive letter. See details on this in the section below.

Once the drive letter change is complete, which usually only takes a second or two, you're welcome to close any open Disk Management or other windows.

The drive letter is different from the volume label. You can change the volume label using similar steps .

If You Have Programs Not on the Main Drive

Changing drive letter assignments for drives that have software installed to them may cause the software to stop working. This isn't quite as common with newer programs and apps but if you have an old program, especially if you're still using Windows XP or Windows Vista, this is likely to be a problem.

Fortunately, most of us don't have software installed to drives other than the primary drive (typically the C drive), but if you do, consider this your warning that you might need to reinstall the software after changing the drive letter.

No Changes for the Operating System Drive

You cannot change the drive letter of the drive that the Windows operating system is installed on. If you'd like Windows to exist on a drive other than C , or whatever it happens to be now, you can make that happen but you'll have to complete a clean install of Windows to do it. Unless you have a pressing need to have Windows exist on a different drive letter, we don't recommend going through all that trouble.

Change, Don't Switch

There's no built-in way to switch drive letters between two drives in Windows. Instead, use a drive letter that you don't plan on using as a temporary "holding" letter during the drive letter change process.

For example, let's say you'd like to swap Drive A for Drive B . Start by changing Drive A's letter to one that you don't plan on using (like X ), then Drive B's letter to Drive A's original one, and finally Drive A's letter to Drive B's original one.

Using the Command Prompt

You can also change the drive letter from Command Prompt . It's not as easy as using Disk Management and you can't see right away which letters are available to choose, but it is completely doable with the diskpart command.

Get the Latest Tech News Delivered Every Day

  • The 34 Best Free Data Destruction Tools of 2024
  • 10 Best Free Disk Partition Software Tools
  • How to Open Disk Management
  • How to Format a Hard Drive in Windows
  • What Is a Volume Label of a Drive?
  • How to Burn an ISO File to a USB Drive
  • How to Partition a Hard Drive (Windows 11, 10, 8, 7, +)
  • How to Back Up Your iPhone to an External Hard Drive
  • How to Properly Reboot (Restart) a Windows Computer
  • What Is a Partition?
  • AOMEI Partition Assistant Standard Edition v10.4.0 Review
  • How to Use the Format Command to Write Zeros to a Hard Drive
  • 12 Best Free Defrag Software Tools (April 2024)
  • What Is the NTFS File System?
  • How to Open Disk Management From Command Prompt
  • What Is a Mapped Drive?

IMAGES

  1. How to Change drive letters or directories in DOS command « Operating

    dos change drive letter assignments

  2. How to Change Drive Letter Assignments

    dos change drive letter assignments

  3. How to change drive letter in Windows 10,8,7 PC or Laptop

    dos change drive letter assignments

  4. Change virtual drive letter assignment

    dos change drive letter assignments

  5. Top 5 Ways to Change a Drive Letter For Storage on Windows 11

    dos change drive letter assignments

  6. Windows 10 change drive letters

    dos change drive letter assignments

VIDEO

  1. How to Change Drive Letter in Windows 10? [Easiest Way]

  2. How to change drive letter in Windows 7/8/10/11

  3. How to Change Drive Letter in Windows 11

  4. How to Change Drive Letter in Windows 10

  5. How to Change Drive Letter in Windows 11/10 [Easiest Way]

  6. How to Change Drive Letter in Windows 10/8/7 [Tutorial]

COMMENTS

  1. Manually assigning a drive letter using CMD/Diskpart

    Procedure. Open up a command prompt (CMD/PowerShell). Type "diskpart" to start up diskpart. You will see the prompt change to "DISKPART>". Type "list vol" to list all available volumes. You can identify the drive by size and file system. Additionally, the volume doesn't currently have a drive letter. Select the volume using "sel vol <number>".

  2. How to change drives in MS-DOS and Windows command line

    How to change drives in MS-DOS and Windows command line. To change the drive letter in MS-DOS, type the drive letter followed by a colon. For example, if you wanted to switch to the floppy disk drive, you would type a: at the prompt. Below is a listing of common drive letters and their corresponding devices.

  3. How to Use the Diskpart Utility to Assign and Remove Drive Letters

    select volume 3. You should see a message that the volume is now selected. At this point you can easily assign a new drive letter. Just type in this command, substituting R for the drive letter you'd like to use: assign letter=R. Make sure to hit enter once you're done, of course. Once you've made that change, your drive should show up again as ...

  4. DOS Command: ASSIGN

    Purpose: Redirects disk drive requests to a different drive. (In DOS Version 6, this program is stored on the DOS supplemental disk.) Discussion Use the ASSIGN command to change drive assignments from the drive indicated by the first letter you enter (x), to the drive indicated by the second letter (y) entered.

  5. How to Remove and Assign Drive Letters in Windows with Diskpart

    Assign Drive Letter Using Diskpart. Assigning a new drive letter to a partition or removable device using Diskpart is really easy. First, search for the command prompt in the Start menu, right click on it and select the option "Run as administrator.". If you are using Windows 8, press "Win + X" to open the power user menu and select the ...

  6. Changing drive letters in MS-DOS 6.22?

    I know of the assign command, but that doesn't actually change the drive letter, it just makes one drive think it's another. Does anyone know anyway to change a drive letter in MS-DOS 6.22? EDIT: So I tried installing the CD-ROM drivers before making any logical DOS drives. and it works, after I made one logical drive it labelled it D, and then ...

  7. Drive letter assignment

    MS-DOS command prompt with drive letter C as part of the current working directory. File Manager displaying the contents of drive C.. In computer data storage, drive letter assignment is the process of assigning alphabetical identifiers to volumes.Unlike the concept of UNIX mount points, where volumes are named and located arbitrarily in a single hierarchical namespace, drive letter assignment ...

  8. DOS Command: ASSIGN

    Purpose: Redirects disk drive requests to a different drive. (In DOS Version 6, this program is stored on the DOS supplemental disk.) Discussion Use the ASSIGN command to change drive assignments from the drive indicated by the first letter you enter (x), to the drive indicated by the second letter (y) entered.

  9. How to Change Drive Letter with CMD Windows 10

    Open CMD in Windows 10. You can press Windows + R, type cmd, and press Ctrl + Shift + Enter to open elevated Command Prompt. Step 2. Open Diskpart tool. In Command Prompt window, you can type diskpart command, and press Enter. This will open the Diskpart command-line utility. Step 3. Change drive letter CMD. Next you can type the command line ...

  10. How to Change a Drive Letter on Windows 10 or Windows 11

    Changing a drive letter is pretty simple. Click the Start button, type "Disk Management" in the search bar, and then hit Enter. The program name displayed in the search will not be Disk Management. It will be "Create and format hard disk partitions." You could also hit Windows+X or right-click the Start button, and then click "Disk Management."

  11. How to assign permanent letters to drives on Windows 10

    Search for Create and format hard disk partitions and click the top result to open the Disk Management experience. Right-click the drive and select the Change Drive Letter and Paths option. Click ...

  12. How to Change a Drive Letter.

    Right-click the disk drive whose drive letter you want to change and select the Change Drive Letter and Paths option. In the window, click the Change button. In the next window, select the letter you desire from the drop-down menu on the right, then click OK. Windows 95, Windows 98, and Windows Me. Open the Device Manager.

  13. Change and Assign Drive Letter in Windows 10

    1 Open an elevated command prompt. 2 Type diskpart into the elevated command prompt, and press Enter. (see screenshot below) 3 Type list volume into the elevated command prompt, and press Enter. 4 Make note of the volume number (ex: 5) for the drive letter (ex: "F") of the drive (volume) you want to change.

  14. 6 Ways to Change the Drive Letter in Windows

    Press Win + I to open the Settings app, then select the "System" tab. Scroll down and click on "Storage.". Scroll down on the right side and click on "Advanced storage settings.". Under Advanced storage settings, click on "Disks & Volumes.". Select the drive whose letter you want to change, then click on the "Properties ...

  15. batch

    Under Storage > Disk Management, right-click on the drive you want to configure and select Change Drive Letter and Paths.... There you can change the drive letter that's assigned to the drive. After this is done, whenever the drive is plugged back in, this letter will be used if it's available.

  16. Can I rearrange drive letters of my mapped network drives?

    Start → Run... (or just press Win + R) Type: "regedit". Navigate to HKEY_CURRENT_USER\Network\. There you will see a list of letters representing your mapped network drives. Right-click the one you want to change and select "Rename". Type your desired new drive letter and close RegEdit. Reboot.

  17. How to Change a Drive Letter

    Right-click and choose Change Drive Letter and Paths > Change. Select the drive letter you want to assign from Assign the following drive letter. Then select OK and choose Yes. The letters assigned to your hard drives, optical drives, and USB drives in Windows are not fixed. Use the Disk Management tool in Windows to change drive letters.