How To Change Drive in CMD
In the Windows command prompt (CMD), we use the
cd command to change from one directory to another. However, it only changes the path inside the current drive by default.
If you want to change to a different drive in CMD, you need to use the
cd /d D:
For example, I am working on the command prompt, inside the
C:\Users\user1 folder. Now I want to move into a folder called data which is in the
In the above screenshot, you can see that the command didn't work. The solution is to use the
Alternatively, simply enter the drive letter followed by a colon, as follows:
However, this method only changes to the root of the drive. If you want to go to a folder, you have to use the CD command.