Share via

OneDrive LongPath Folder Error Issue - Windows 11 Pro

Ruben L 0 Reputation points
2025-10-18T15:53:56.5266667+00:00

Seems there is an error in Window 11 Pro for enabling long path folder for OneDrive.

I have just updated the Windows 11 Pro to Version 25H with these two updates:

2025-10 Cumulative Update for Windows 11 Version 24H2 for x64-based Systems (KB5066835) (26100.6899)

2025-10 Cumulative Update for .NET Framework 3.5 and 4.8.1 for Windows 11, version 24H2 for x64 (KB5066131)

I have already set all the required setting to enable long path for OneDrive in Registry Editor and Edit Group Policy

User's image

User's image

But it is still does not work. I still getting long path error notification

User's image

Is there anyway to fix these issues ?

Microsoft 365 and Office | OneDrive | For business | Windows

3 answers

Sort by: Most helpful
  1. Kai-L 13,380 Reputation points Microsoft External Staff Moderator
    2025-10-23T22:15:21.88+00:00

    Dear @Ruben L,
    Thank you for your update. I am sorry to hear that the "path is too long" notification is still persisting.

    From my research, even if you enable the Windows system setting for long paths, shortening the path remains the only reliable and supported solution. While the Windows system limit might allow for paths up to approximately 300 characters, the OneDrive sync mechanism itself imposes a stricter ceiling, usually around 255-260 characters for the full path. When you exceed this, we must reduce the character count.

    Here are the most effective path-shortening techniques, presented as workable solutions:

    1: Shorten the OneDrive Root Folder (Most Effective)

    Changing the name of the main OneDrive folder on your local drive removes a large chunk of characters from every single file path, often solving the problem instantly.

    1. Unlink OneDrive: Right-click the OneDrive cloud icon in your system tray and select Settings (the gear icon).
    2. Go to the Account tab and click Unlink this PC. (This is necessary to safely change the folder location).
    3. Relaunch Setup: When OneDrive asks you to sign in again, follow the setup prompts.
    4. Change Location: When it prompts you for the folder location, click Change Location.
    5. Choose a simple, short path, such as C:\OD or C:\Cloud, instead of the default long path (e.g., C:\Users\YourName\OneDrive - Personal).
    6. Select Use this folder. OneDrive will resync your files to this new, shorter location.

    2: Shorten Nested Folder and File Names

    If the issue is only with a few deeply nested files, you can modify the names of the specific folders that lead to them.

    • Rename Folders: Use the OneDrive web interface or your File Explorer to rename deeply nested folders (e.g., change 2024_Q3_Project_Documentation_Review to Q3-DOCS).
    • Rename Files: Shorten the file names themselves (e.g., change Final_Draft_of_Quarterly_Report_v2.docx to QReport_Final_v2.docx).

    3: Unsync Deep Folders (If Path Cannot Be Shortened)

    If you cannot shorten the path (e.g., due to organizational naming conventions) and still exceed the character limit, the only option is to stop that specific folder from syncing locally:

    1. Access OneDrive Settings: Right-click the OneDrive cloud icon in your system tray and select Settings.
    2. Go to the Account tab and click Choose folders.
    3. Uncheck the box next to the long, problematic folders.
    4. Click OK. This removes those folders from your local hard drive, eliminating the path error. You can still access and work with these files via OneDrive online in your web browser.

    I hope this information helps clarify the situation and provides you with workable solutions. Should you have any further questions or need additional assistance, please don't hesitate to reach out. We're always here to help. Have a wonderful day!

    If you found the answer helpful, we kindly invite you to mark it as the accepted answer. Once marked, it will automatically be pinned to the top. Since many other users also search for information in this community, your valuable contribution will help them easily find the right channel and useful insights more quickly. 


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".  

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. 
    User's image

    Was this answer helpful?

    1 person found this answer helpful.

  2. Ruben L 0 Reputation points
    2025-10-23T14:07:58.27+00:00

    Hi @Kai-L ,

    I have tried you solution but so far no luck.

    I followed your step-by-step instruction yet I still keep getting the 'the path is too long' notification

    User's image

    I even tried uninstall the OneDrive and install it again but that does not work either.

    Hope you have other solution for this issue.

    Was this answer helpful?

    0 comments No comments

  3. Kai-L 13,380 Reputation points Microsoft External Staff Moderator
    2025-10-18T16:48:26.66+00:00

    Dear @Ruben L,

    Thank you for reaching out to the Microsoft Q&A Forum.

    I'm truly sorry to hear that you're experiencing a persistent issue with OneDrive, especially since you have correctly configured both the Registry and Group Policy settings in Windows 11 Pro. Since you've already verified the configuration and applied the latest Windows updates, the issue is likely due to a software conflict, a failure of the configuration to fully propagate, or a strict limit imposed by the OneDrive sync client itself.

    Here is the troubleshooting plan:

    1.Force Group Policy Update:

    • Click the Start button or the Search icon on your taskbar.
    • Type cmd (for Command Prompt).
    • In the search results, right-click Command Prompt and select Run as administrator.
    • Type the following command and press Enter: gpupdate /force
      Restart your computer after the update completes.

    For reference: gpupdate | Microsoft Learn

    2.Restart OneDrive Sync Client:

    • Right-click the OneDrive cloud icon in the system tray.
    • Go to Settings > Account tab.
    • Click Unlink this PC (this will not delete your files).
    • Set up OneDrive again, ensuring you link to the same folders. This forces the client to re-read system policies.

    3.Check the OneDrive Sync Limit:

    Ensure that the total path length (including the drive letter, your OneDrive folder name, and the entire file path) is under the theoretical maximum of 400 characters. While the Win32 setting extends the OS limit, the cloud service's internal limit may still trigger the error. If the path is too long, you will need to shorten the names of the folders higher up in the hierarchy.

     If none of the above solutions work, let me know for further investigation. Please note that our initial response does not always resolve the issue immediately. However, with your help and more detailed information, we can work together to find a solution. Thank you for your patience and understanding. I'm looking forward to your reply. 


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".  

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. 
    User's image

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.