Hide Office 365 Group from GAL using PowerShell

Requirement: Hide Office 365 Group from GAL (Global Address List)

How to Hide Office 365 Group from GAL using PowerShell?

If you don’t wish your Office 365 group appears in the global address list (GAL), you can hide it from appearing in GAL using the Set-UnifiedGroup cmdlet. Here is how to hide the group from the address list:

#Get Credentials to connect
$Credential = Get-Credential

#Connect to Exchange Online
Connect-ExchangeOnline -Credential $Credential -ShowBanner:$False

#hide office 365 group from gal using powershell
Set-UnifiedGroup -Identity "[email protected]" -HiddenFromAddressListsEnabled $True

#Disconnect Exchange Online
Disconnect-ExchangeOnline -Confirm:$False

This PowerShell hides Office 365 Group from GAL. Similarly, You can hide Office 365 group from Exchange clients using:

Set-UnifiedGroup -Identity "[email protected]" -HiddenFromExchangeClientsEnabled:$True
hide office 365 group from gal using powershell

This hides the group from the Groups section in Exchange clients like OWA.

Salaudeen Rajack

Salaudeen Rajack - SharePoint Expert with Two decades of SharePoint Experience. Love to Share my knowledge and experience with the SharePoint community, through real-time articles!

One thought on “Hide Office 365 Group from GAL using PowerShell

  • Is there a way to apply it to all groups?

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *