SharePoint - The URL is invalid. It may refer to a nonexistent file or folder, or refer to a valid file or folder that is not in the current Web.


The user receives the error message 'URL is invalid' while uploading the file to SharePoint Online or SharePoint 2013 document library. The problem is not limited to any specific file format, it may occur with Docx, xlsx, pdf, others.

The URL [file name] is invalid. It may refer to a nonexistent file or folder, or refer to a valid file or folder that is not on the current Web.

SharePoint file upload URL is invalid
SharePoint file upload URL is invalid

How to fix URL is invalid SharePoint error

Version Column

The problem may occur when the Version column is configured as an Indexed Column. Remove the Version column from the list of Indexed Columns to fix.

  1. Navigate to the library/list with problem.
  2. From Ribbon --> Library tab --> Library Settings.
  3. Click Fields --> Indexed Columns.
  4. Click Indexed Columns --> Version.
  5. Click Delete --> click OK.
  6. Re-upload the problematic file again.

Invalid Date

The problem may occur when the default value for date column is incorrect, maybe an invalid format. Make sure the value for the date/time filed is in the expected format.

Make necessary changes and re-try, the file should be uploaded now.

Characters exceeding The problem may occur when the file name exceeds the maximum character limit. SharePoint document's URL can be up to 400 characters long. Avoid long path names. Copy file contents

The problem maybe sometimes with the file itself and not the contents. Copy the contents to a new file and try uploading, this works in many cases.PE| More help with ULS logs

If you still can't figure out the problem, check SharePoint logs (C:\Program files\Common Files\Microsoft Shared\Web Server Extensions\14\LOGS) or ask Microsoft support to provide you the logs, deep dive into the logs to find the issue and fix. Contact Microsoft Support for further help

Have Questions? Post them here!
Try Out Code2care Dev Tools:


Android Java Linux Microsoft Google Python macOS Notepad++ Microsoft Teams CSS PHP SharePoint Html Linux C Programs Bootstrap jQuery Sublime Android Studio Facebook Eclipse WhatsApp News MySQL Json HowTos JavaScript FTP S3


Code2care is an initiative to publish and share varied knowledge in programming and technical areas gathered during day-to-day learnings and development activities.

Students and Software Developers can leverage this portal to find solutions to their various queries without re-inventing the wheel by referring to our easy to understand posts. Technical posts might include Learnings, Tutorials, Trouble-Shooting steps, Video Tutorials, Code Snippets, How Tos, Blogs, Articles, etc.
🎉 We are celebrating the 10th years of Code2care! Thank you for all your support! We hope we made a difference.
We strong support Gender Equality & Diversity.

We stand in solidarity with Ukraine - Make a donation to UNHCR -