How to Use Robocopy to Transfer Files (Copy All Folders and Files)

You may want to transfer all your files to the new computer after you set up Windows 10. Usually, you are able to use an external storage to copy the files and move them over to the new device. Or if you are a tech-savvy user, you may transfer the files over to the network by using file share. While those are all nice options, depending on the amount of data you want to transfer, using File Explorer, the process is able to take a long time. If you want to copy many files faster and more reliably, you have to use a Robocopy.

Robocopy or Robust File Copy is a command-line tool built into Windows 10. It is a powerful and flexible tool to transfer files very fast. In this article, we are going to share the steps on how to use Robocopy to transfer a lot of files on Windows 10.

HOW TO USE ROBOCOPY TO COPY FOLDERS AND FILES

One of Robocopy’s features is to offer you to copy files very quickly. However, you have to remember that you will need a wired connection for the best experience. The time to complete the transfer is going to depend on the network connection speed and drive performance. This is a two-step process. First, you have to configure file sharing on the source device, and then you have to use Robocopy in the destination device to perform the transfer.

Configuring file sharing on Windows 10

To copy files between two computers, you have to enable file sharing in the source device to let Robocopy access to copy the files from the destination device. To share files on your local network by using the express settings, do these steps below:

  • At the first step, you have to Open File Explorer on Windows 10
  • Please navigate to the folder with the files which you want to migrate.
  • Then, you have to right-click the folder, and choose the Properties option.

select the Properties option

  • On the Properties page, you are able to click the Sharing tab.
  • In this step, you need to click the Share button

click the Share button

  • Please use the drop-down menu to choose the user or group to share a file or folder.
  • Simply, click the Add button

click the Add button

  • Under Permission Level, you are able to choose the type of sharing permissions you wish the folder to have. For instance, you are able to choose Read (default) if you only want the users to enable view and open files. If you choose Read/Write, the users are able to view, open, modify, and remove the content on the folder you are sharing.
  • The next step that you have to do is to click the Share button.

click the Share button1

  • You have to note the network path for the folder which other users will need to access the content over the network, and then click the Done button.
  • Lastly, you only need to click the Close button.

you only need to click the Close button

If you have completed the steps above, now you have to note the folder path and the IP address of your source computer. For your information, you are able to find out your IP address quickly on Settings -> Network & Internet, click Wi-Fi or Ethernet, and then click the connection to view the information.

After file sharing is configured on the source device, you will be able to proceed to copy the files by using Robocopy from the destination device.

To use Robocopy to copy files on Windows 10 quickly, you have to do these steps below:

  • Firstly, you have to open Start.
  • Please search for Command Prompt, right-click the top result, and then choose the Run as administrator option.
  • After that, you are able to type the following command to copy the files over the network and simply press Enter:

robocopy\\source-device-ip\path\to\share\folderC:\destination device\path\to\store\files /E /Z /ZB /R:5 /W:5 /TBD /NP /V /MT:16

In the above command, you need to ensure to change the source and destination paths with your configuration.

ROBOCOPY COMMAND OPTIONS EXPLAINED

Robocopy has many features that you can use. In the command shown in this page, we are using the following options to create copy reliable and fast.

  • /S: This will copy subdirectories, but not empty ones.
  • /E: This will copy Subdirectories, including empty ones.
  • /Z: This will copy files in restartable mode.
  • /ZB: You are able to use restartable mode, if access denied use backup mode.
  • /R:5: This will retry 5 times (you are able to determine a different number, default is one million).
  • /W:5: This means that you have to wait 5 seconds before retrying. You will be able to specify a different number, the default is 30 seconds.
  • /TBD: This means that you have to wait for sharenames to be defined.
  • /NP: This means that there is no Progress, you do not display percentage copied.
  • /V: This will produce verbose output, displaying skipped files.
  • /MT:16: This will do multithreaded copies with ‘n’ threads. For your information, the default is 8.

Probably the most important switch to pay attention is /MT, which is a feature which allows Robocopy to copy files in multithreaded mode. Usually, when you copy files by using File Explorer, you are only copying one file at a time, but with multithreaded enabled, you will be able to copy multiple files at the same time better using the bandwidth and significantly speeding up the process. If you do not set a number once you are using the /MT switch, then the default number is going to be 8. It means that Robocopy is able to try copying eight files at the same time, however the tool supports 1 to 128 threads.

In the command shown in this page, we are utilizing 16. However, you are able to set it to a higher number. The only note is that the greater the number, the more processing power and bandwidth will be used. While if you have an older processor and an unreliable network connection, it may cause the problems. Ensure to test the command before you execute the command with a high number of threads.