In Windows 10 21H2 have LongPathsEnabled set to 1 in the registry, via group policy, but even though that's supposed to allow paths up to 32K characters, Windows Explorer is unable to create them—even though PowerShell can, but if you create deeper folders or files in PS, they aren't viewable in Explorer. If I create C:\Users\UserName\OneDrive - Company Name\Documents 1\TestLongFolder-FileName-Folder1-12345678901234567890123456789012345678901234567890\TestLongFolder-FileName-Folder2-12345678901234567890123456789012345678901234567890\TestLongFolder-FileN\New Document.txt It won't let me make either the laster folder or document name any longer, nor nest another folder in them with a name longer than that last file. While this is 269 characters, which is more than the 260 that is allowed without LongPathsEnabled, it's far less than the 32,000+ characters that are supposed to be allowed with it enabled. Please let me know this limitation been fixed in Windows 11, or is there a way around it in Win 10? Thanks, Ralph.
Asked
Active
Viewed 2,902 times
1
-
What about something that is not on OneDrive? – Anders Sep 11 '22 at 23:14
-
Even if I create the folders and text file below in C:\temp, I'm still unable to use a longer path than that. It won't allow me to create a subfolder in it, giving the error "The file name(s) would be too long for the destination folder. You can shorten the file name and try again, or try a location that has shorter path." C:\temp\testLongFolder-FileName-Folder1-12345678901234567890123456789012345678901234567890\testLongFolder-FileName-Folder2-12345678901234567890123456789012345678901234567890\testLongFolder-FileName-Folder3-12345678901234567890123456789012345678901\New Text Document.txt – Ralph Smorra Sep 12 '22 at 03:34
-
I have the same issue. What I find really troubling about the File Explorer app is that I can see files whose paths exceed the 260 character limit, but when I select one, I get the following bogus error in the preview pane, _"The file you are attempting to preview could harm your computer..."_ Why not give a useful error like, _"The file you are attempting to preview exceeds File Explorer's 260 character path limit."_ It would have saved me a lot of time trying to figure out what the problem was. – SLax Jan 23 '23 at 21:17
2 Answers
1
The only way I have found around this so far is to zip up files and then unzip them into the deeper directory.
I know this doesn't really help in a lot of cases but might be helpful to someone.

ODG
- 11
- 1
0
I got up to 343 characters then ran into the same problem. You can create longer directories in the CMD prompt using the MD command, but not in Windows Explorer. My application would either need a rewrite or at the least to use an alias of some kind. The internet browser temporary cache does not seem to have this limitation.

Clay
- 1
- 2