Commands › Exchange Online

Enable-DistributionGroup

Exchange Online ExchangeOnlineManagement Enable-*

Mail-enable existing universal security groups and universal distribution groups that aren't already mail-enabled.

Quick start script

# Enable-DistributionGroup — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-ExchangeOnline -CertificateThumbprint $thumb -AppId $appId -Organization $org

# 2. Capture the current state first — you cannot roll back what you never recorded
$before = Get-DistributionGroup
$before | Format-List

# 3. Make the change (dry run first)
Enable-DistributionGroup -Identity <GroupIdParameter> -WhatIf
Enable-DistributionGroup -Identity <GroupIdParameter>

# 4. Verify and diff
$after = Get-DistributionGroup
Compare-Object ($before | Out-String) ($after | Out-String)

Syntax

Enable-DistributionGroup [-Identity] <GroupIdParameter>
 [-Alias <String>]
 [-Confirm]
 [-DisplayName <String>]
 [-DomainController <Fqdn>]
 [-PrimarySmtpAddress <SmtpAddress>]
 [-WhatIf]
 [<CommonParameters>]

Parameters (7)

ParameterTypeRequiredWhat it controls
-Identity GroupIdParameter yes The Identity parameter specifies the universal security group or universal distribution group that you want to mail-enable. You can use any value that uniquely identifies the group. For example:
-Alias String The Alias parameter specifies the Exchange alias (also known as the mail nickname) for the recipient. This value identifies the recipient as a mail-enabled object, and shouldn't be confused with multiple email...
-Confirm SwitchParameter The Confirm switch specifies whether to show or hide the confirmation prompt. How this switch affects the cmdlet depends on whether the cmdlet requires confirmation before proceeding.
-DisplayName String The DisplayName parameter specifies the display name of the group. The display name is visible in the Exchange admin center and in address lists. The maximum length is 256 characters. If the value contains spaces,...
-DomainController Fqdn The DomainController parameter specifies the domain controller that's used by this cmdlet to read data from or write data to Active Directory. You identify the domain controller by its fully qualified domain name...
-PrimarySmtpAddress SmtpAddress The PrimarySmtpAddress parameter specifies the primary return email address that's used for the recipient.
-WhatIf SwitchParameter The WhatIf switch shows what the command does without making any changes. You don't need to specify a value with this switch.

Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.