When you're unable to boot into Windows or simply want to explore alternative file management methods, you can always use Command Prompt (CMD) to transfer data from your hard drive to a USB. For copying individual files, you can use the copy command. However, if you want to copy an entire directory, including subfolders and files within, it's better to use the xcopy command. This guide explains how to use both copy and xcopy to copy files and folders using Windows Command Prompt.
Steps

- Press Windows key + S to open the search bar.
- Type cmd into the search bar.
- If you need to copy system files, right-click on Command Prompt and select Run as administrator.
- You don't need to do this if you've booted into recovery mode, as you'll always have administrative access to Command Prompt.
- If you're copying personal files, such as images or documents, simply click on Command Prompt.

- Enter or paste this command after the prompt:wmic logicaldisk where drivetype=2 get deviceid, volumename, description
- Press Enter.

- Type cd F: (if the USB drive is not F:, replace it with the correct drive letter) and press Enter.
- Type mkdir foldername and press Enter (replace foldername with the name you want for the new folder).

- If the folder name contains spaces, such as C:\Users\yourname\personal files, enclose the entire path in quotes like this: cd "C:\Users\yourname\personal files.
- To view all files in the folder, type dir and press Enter.
- Type dir and press Enter to see the current files and folders. All folders are marked as ''<DIR>'' to indicate they are directories, not files.

- When using the copy command, enter the following: copy sourcefolder destinationfolder. For example, to copy the file cats.docx from a folder to the Pets folder on a USB with the drive letter F:, the command would be:
- copy cats.docx F:\Pets\
- If you want to copy multiple individual files with the same extension (e.g., .docx) to the Pets folder on the USB, type copy *.docx F:\Pets\.

- xcopy "C:\Users\yourname\personal files\" F:\ /e /h /r
- The backslash \ at the end of the first path instructs xcopy to copy the folder, not individual files.
- Add /e to ensure xcopy copies all subfolders.
- Add /h to include hidden files in the copy.
- Add /r to copy read-only files.
