Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to make backups of some files on a network share. However, I need to copy those files to my local drive before burning the disks because those files might be in use. Some of the files won't copy because the file path is too long. Is there any workaround other than changing the file structure?

share|improve this question
See also Window 256 characters path name limitation. – Gilles Dec 1 '10 at 0:59
up vote 19 down vote accepted

Maximum path length is 260 in Windows Vista/7. I can recommend three solutions:

  • (if the path is too long) First copy the folder to upper levels in windows explorer and then move it to your local computer
  • (if file names are too long) First try to zip/rar/7z them with an archive application and then copy the archive file to your local computer and then extract the contents.
  • Use third party apps.

All of these suggestions assume you have some sort of write access on the network shared folder/computer. If you can't do any of these then you might need help from your administrator.

share|improve this answer
zipping the files worked! – Brian Sturm Nov 30 '10 at 21:19
@BrianSturm, Well, assuming they are 3rd party apps – Pacerier May 16 '15 at 0:24
Although I really hate this about Windows...the zip solution really saved my day. Thanks! – Bas Slagter Sep 18 '15 at 8:43
robocopy /E source destination

Robust File and Folder Copy.

Windows 7 and above:
Robocopy XP027 is a standard command on Windows 7 and above.

NT 4/ Windows 2000:
The Windows Server 2003 Resource Kit Tools include Robocopy XP010,
which can be run on NT 4/ Windows 2000.

Windows 95, or NT 3.5:
Robocopy does not run on Windows 95, or NT 3.5. (Robocopy is a Unicode application).

Windows 95, or NT 3.5 workaround:
The Microsoft Robocopy GUI will install Robocopy XP026 to C:\Windows\system32,
this version can run on older OS's,
and includes some features from XP027 (/BYTES) but has competely broken errorlevel handling.

Robocopy 'Jobs' and the 'Monitor source' option provide an alternative to setting up a Scheduled Task to run a batchfile with a Robocopy command.

share|improve this answer
This is the solution. If you want to turn OFF support for paths with length greater than 256, pass in the /256 flag. Thanks a lot! I have struggled with this all day. – Cort3z Apr 26 '15 at 0:40
amazing! Solution i never know until now this bult-in solution. – SIslam Oct 12 '15 at 8:01

You can access path lengths up to ~32K characters by prefixing with \\?\.


This works from the command prompt and any other programs which use the Win32 Unicode Api methods, including .Net apps. It does require a file system that supports long paths (eg NTFS) but if you have a long path problem, that's a given.

Note that certain applications and a lot of native tools (like Explorer) will have problems with these paths so use this to get yourself out of a hole, not into one.

share|improve this answer
This is a really great tip. I also works to get around handling com1, com2 etc filenames. – Andreas Reiff Jan 6 '15 at 11:58

How does this suit you.

In Regedit browse to this folder

and set the following value to 0

share|improve this answer
Can you elaborate? – CodyBugstein Aug 26 '13 at 5:41
@Joe, Are you sure this works? – Pacerier May 16 '15 at 0:24
didn't work for me... can you elaborate how this works? – Idan Jun 29 '15 at 11:52
That reg entry can cause data loss in certain scenarios. – Overmind Oct 12 '15 at 10:14

Quickest fix I used in this situation was to rename the over-long name folders to something like "1".

Also, as a general practice, I try to explain all users not to put their life story into a file or folder name.

share|improve this answer

protected by slhck Sep 13 '12 at 13:13

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.