Invalid file names and file types in OneDrive, OneDrive for Business, and SharePoint

Invalid file names and file types in OneDrive, OneDrive for Business, and SharePoint

Invalid file or folder characters

Certain characters have special meanings when used in file names in OneDrive, SharePoint, and Windows, such as "*" for wildcards, and "\" in file name paths. If a file or folder you’re trying to upload to OneDrive contains any of the characters listed below, it may prevent files and folders from syncing. Rename the file or folder to remove these characters before you upload it.

To rename a file or folder in Windows, select it and press F2. To rename a file or folder on a Mac, select it and press the 'return' key. 

Characters that aren't allowed in file and folder names in OneDrive, OneDrive for Business on Office 365, and SharePoint Online

Characters that aren't allowed in file and folder names in OneDrive for Business on SharePoint Server 2013

" * : < > ? / \ |

(Windows also blocks all these characters. If you're using Office 2010, you also can't use "&" in file and folder names.)

~ " # % & * : < > ? / \ { | }.

Invalid file or folder names

These names aren't allowed for files or folders: AUX, PRN, NUL, CON, COM0, COM1, COM2, COM3, COM4, COM5, COM6, COM7, COM8, COM9, LPT0, LPT1, LPT2, LPT3, LPT4, LPT5, LPT6, LPT7, LPT8, LPT9.

Additionally, you can’t create a folder name in SharePoint Online from the browser that begins with a tilde (~).

File name and path lengths

The entire path, including the file name, must contain fewer than 400 characters for OneDrive, OneDrive for Business and SharePoint Online. If you exceed that limit, you'll receive an error message. SharePoint Server versions only support up to 260 characters for file and path lengths.

Invalid or blocked file types

There are no blocked file types in OneDrive, but there are some restrictions in SharePoint Server and OneDrive for Business on Office 365. For more info, see Types of files that cannot be added to a list or library.

You can't upload types of files that are blocked on your organization’s SharePoint site. The list of blocked files may vary depending on what your administrator sets up. For security reasons, a number of file names and extensions can't be uploaded since they are executable, used by SharePoint Server, or used by Windows itself.

For more information about restrictions and limitations, like size limits for syncing files, and character limits for files and folders, see Restrictions and limitations when you sync SharePoint libraries to your computer through OneDrive for Business.

Connect with an expert
Contact us
Expand your skills
Explore training

Was this information helpful?

Thank you for your feedback!

Thank you for your feedback! It sounds like it might be helpful to connect you to one of our Office support agents.

×