Prevent users from sharing content with “Everyone” in SharePoint Online

New capabilities were recently added to the SharePoint Online Management Shell that allow us to block users from being able to share content with either “Everyone” or “Everyone except external users”.

To do this, fire up the SharePoint Online Management Shell, and connect as usual:

Connect-SPOService -url https://somesite-Admin.sharepoint.com

To view the current settings:

Get-SPOTenant

get-spotenant

The current sharing dialog before changing any settings:

everyone-before

To hide “Everyone”:

Set-SPOTenant -ShowEveryoneClaim $false

everyone-after

The “Everyone except external users” can be hidden easily as well:

Set-SPOTenant -ShowEveryoneExceptExternalUsersClaim $false

Of course, to turn it back on just run the same command with $true. Note, nothing further has to be done to get these commands to take effect. The next time a user clicks “share”, these items will be hidden.

Advertisements

2 thoughts on “Prevent users from sharing content with “Everyone” in SharePoint Online

    1. Mike G Post author

      If a folder has already been shared with Everyone, that will not be modified after running this command. This command only affects whether or not the group can be assigned permissions, but does not impact existing permissions.

      Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s