Last month, we reported that Microsoft was working on a new Office 365 policy that would allow admins to prevent users from uploading specific files to OneDrive or SharePoint. The Microsoft 365 roadmap entry indicates that a new OneDrive update (version 20.201) that supports this new policy is now rolling out for all users globally.
To block the upload of specific file types, you’ll need to go to the OneDrive Admin Center and click the “Sync” option available in the left pane. Now, select the “Block syncing of specific file types” option, and type all the file name extensions you want to block. Finally, hit the “Save” button on the Sync page, and restart the OneDrive sync app.
“If you enable this setting, the sync app doesn’t upload new files that match the keywords you specified. No errors appear for the skipped files, and the files remain in the local OneDrive folder. In File Explorer, the files appear with an “Excluded from sync” icon in the Status column. The OneDrive sync app must be restarted after this setting is enabled for the setting to take effect,” the company explained.
Once this Group policy is enabled, users will still be able to upload excluded files from their local OneDrive folder by using the OneDrive for Business web app. However, the company recommends users to delete the excluded local file in the OneDrive folder to prevent a sync conflict with that skipped file. You can learn more details about this new Group Policy on this support page.