How to enable or disable long path lengths in Windows 11
On Windows 11, long path support is enabled/disabled through a Group Policy or Registry setting. By default, Windows 11 allows paths longer than 260 characters, but sometimes it’s still restricted depending on application compatibility.
Here’s how you can disable long path support (go back to 260-character limit):
Method 1: Group Policy Editor (Pro, Enterprise, Education editions)
- Press Win + R, type
gpedit.msc
, and press Enter. - Navigate to:
3.
Local Computer Policy >
4.
Computer Configuration >
5.
Administrative Templates >
6.
System >
7.
Filesystem
- Find Enable Win32 long paths in the right pane.
- Double-click it → set to Disabled → click Apply → OK.
- Restart your PC for changes to take effect.
Method 2: Registry Editor (All editions, including Home)
- Press Win + R, type
regedit
, and press Enter. - Navigate to:
3.
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem
- Find the DWORD value: LongPathsEnabled.
- If it doesn’t exist, create a new DWORD (32-bit) Value named
LongPathsEnabled
.
- If it doesn’t exist, create a new DWORD (32-bit) Value named
- Set its value to:
- 0 → Disabled (enforce 260-character limit)
- 1 → Enabled (allow >260 characters)
- Restart your PC.
⚠️ Note: Disabling long path support may cause issues if you already have files or folders with paths longer than 260 characters — they may become inaccessible until you shorten or move them.