0

How we can restrict to users to upload only few files types in Document Library (SharePoint Online, Modern Communication Site).

I have two libraries one can accept only .pdf and .zip and another can accept only .pdf.

I am using SharePoint Online Modern Communication site, and Document Library.

1 Answer 1

1

This is not possible in SharePoint Online using OOTB capabilities of SharePoint.

However there are some workaround to achieve this:

  1. Create an Event receiver to check the file type before uploading it to Document library like given at: Restrict File Types in SharePoint Document Library Upload using Event Receiver.
  2. Create a Microsoft Flow which will check the file type and if it is not the desired file type you want then you can delete that file from document library (Additionally you can email an user who uploaded it informing you are deleting that file) .
  3. Creating a SharePoint designer workflow (If you don't have license to create Microsoft flow) which will act similar to Microsoft flow.

Similar Threads:

  1. How To Restrict Files Uploaded To SharePoint Online?.
  2. Can we restrict specific file type uploading on sharepoint library?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.