How to Fix Destination Path Too Long in Windows 11
In this article
The fastest fix is to enable long paths in Windows 11: open Registry Editor, navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem, set LongPathsEnabled to 1, then restart your PC. If you would rather not edit the registry, shorten the folder names or move the files in smaller batches instead. This guide covers both approaches, plus the mistakes that make the error come back.
What You'll Need
- A Windows 11 PC with administrator rights (needed for the registry change).
- The exact source and destination folder paths, so you can measure how long they are.
- Enough free space at the destination for the files you are moving.
- Optional: a backup of important files before you change system settings.
Step-by-Step
- Confirm the error is really about path length. The message usually says the file name or path is too long, or that the destination path exceeds the limit. Windows historically caps paths at 260 characters (the MAX_PATH limit). If your combined source and destination path is near or over that, this is your issue.
- Measure the path. Right-click the file or folder, choose Properties, and note the location. Add the destination folder path plus the file name. If the total is over roughly 260 characters, shortening it will help even without a registry change.
- Try the simplest fix first: shorten the destination. Create the destination folder closer to the drive root, for example C:\Move instead of a deeply nested folder. Move the files there, then move them again into the final deep folder if you still need to.
- Rename long folder names along the way. A folder called "Important Project Documents 2024 Final Version" can become "Proj2024". Shorter names at every level reduce the total path length.
- Move in smaller batches. Instead of moving a whole tree at once, move one subfolder at a time. This avoids hitting the limit on the deepest files while the rest copy fine.
- Enable long paths in the registry (the permanent fix). Press Windows key + R, type regedit, and press Enter. Accept the administrator prompt. Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem. In the right pane, double-click LongPathsEnabled. If it does not exist, right-click in the right pane, choose New > DWORD (32-bit) Value, and name it LongPathsEnabled. Set the value to 1 and click OK. Registry labels can differ slightly by Windows version, but this key is present in Windows 11.
- Restart your PC. The setting takes effect after a restart. Then try the move again.
- If you prefer not to touch the registry, use a command-line copy. Open File Explorer, navigate to the source folder, click the address bar, type cmd, and press Enter. Use the robocopy command to copy the folder to the destination, for example: robocopy "C:\Source\Folder" "D:\Destination\Folder" /E. Robocopy handles long paths better than drag-and-drop in many cases. Review the output before deleting the source files.
- Check the result. Open the destination folder and confirm the files are present and open correctly. Only then remove the originals if that was your plan.
Common Mistakes
- Editing the wrong registry key. The LongPathsEnabled value belongs under Control\FileSystem, not under a random subkey. Changing unrelated values can affect system behaviour.
- Forgetting the restart. The registry change does not apply to already-running processes; a restart is the reliable way to make it stick.
- Assuming every app respects long paths. Some older programs still fail on very long paths even after the registry change. Shortening the path remains the safest fix.
- Moving instead of copying first. If a move fails partway, you can end up with files in two places. Copy first, verify, then delete the source.
- Renaming system folders. Do not rename Windows, Program Files, or user profile folders to shorten paths; that can break applications.
Tips
- Keep folder structures shallow. A few levels deep is usually enough for personal files.
- Use short, descriptive names rather than long sentences.
- When archiving, consider zipping a deep folder and moving the single archive file instead.
- If you use cloud sync folders, check whether the sync client creates extra nested folders that add to the path length.
- Before making registry changes, create a restore point so you can roll back if something behaves unexpectedly.
Troubleshooting
If the error persists after enabling long paths and restarting, work through these checks in order.
- The move still fails in one app but works in another. The app may not support long paths. Use File Explorer or robocopy for that transfer, or shorten the path.
- Robocopy reports errors. Read the summary at the end. Access-denied errors usually mean you need to run the command prompt as administrator or check folder permissions.
- Files appear but will not open. The copy may have been interrupted. Re-run the copy and compare file counts and sizes.
- You cannot find LongPathsEnabled. Create the DWORD value yourself as described in step 6, set it to 1, and restart.
- You want to undo the change. Set LongPathsEnabled back to 0 and restart. This restores the previous behaviour.
Frequently Asked Questions
What is the maximum path length in Windows 11?
By default, many Windows APIs still use a 260-character limit. Enabling long paths raises that limit for compatible apps, but some older software may still enforce the old limit.
Does enabling long paths affect all programs?
No. It helps apps that are written to check the setting. Older apps that hard-code the 260-character limit may still fail, so shortening the path is a reliable fallback.
Can I fix this without editing the registry?
Yes. Shorten the destination folder path, rename long folders, move files in smaller batches, or use robocopy from Command Prompt.
Is it safe to change the registry?
Changing this specific value is generally safe when done correctly, but registry edits carry risk. Create a restore point first, and change only the LongPathsEnabled value.
Why does the error appear when I move files but not when I copy them?
Move operations can behave differently from copy operations depending on the app and the file system. If a move fails, copy the files to the new location, verify them, then delete the originals.
Will this fix work on external drives?
The long path setting applies to the system, but the destination drive must use a file system that supports the file names and paths involved. If problems continue on an external drive, shorten the path on that drive as well.