To create a Microsoft 365 group using PowerShell, you can follow these steps:

Connect to Microsoft 365 Exchange Online PowerShell by running the following command in the PowerShell console:

Connect-ExchangeOnline

Once you are connected, you can create a new Microsoft 365 group using the following command:

New-UnifiedGroup -DisplayName "My Group Name" -Alias "mygroup" -AccessType "Public"

In this example, the -DisplayName parameter is used to set the display name of the group, the -Alias parameter sets the email alias of the group, and the -AccessType parameter sets the privacy level of the group.

You can set the -AccessType parameter to “Private” if you want the group to be private and only accessible to invited members.

After running the command, you can verify that the group has been created by running the following command:

Get-UnifiedGroup -Identity "mygroup"

This will display the properties of the newly created group.

That’s it! You have now created a Microsoft 365 group using PowerShell. You can also use PowerShell to manage and configure your Microsoft 365 groups as needed.


Discover more from Blogs | Saied Taki

Subscribe to get the latest posts sent to your email.

By Taki

Leave a Reply

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