Removing Email Addresses from Microsoft 365 Groups

MC146221 Microsoft 365 groups

The Curious MC146221 Update

Microsoft published update MC146221 in the Microsoft 365 Message Center on August 8, 2018. The text is a masterpiece of obfuscation. It announces a new feature, but really what is happening here is that Microsoft has fixed a bug in the Set-UnifiedGroup cmdlet so that you can remove proxy email addresses from a Microsoft 365 Group. Although the notice says that Microsoft is releasing a new cmdlet, it’s just a fix for a cmdlet that’s been around since the introduction of Microsoft 365 Groups in November 2014.

Reclaiming an Email Address

When Microsoft says that “it was not possible to reclaim email addresses of Groups,” it means that the Set-UnifiedGroup cmdlet didn’t work when you tried to remove a proxy address from the set in a group’s EmailAddresses attribute. The bug has now been fixed.

In the following example, we examine the set of addresses for a group and then remove one. When we check the EmailAddresses attribute again, the address we removed is gone, which is what we want. In Microsoft terms, the address is reclaimed because it can now be assigned to another mail-enabled object.

Get-UnifiedGroup -Identity BankingTeam | select -ExpandProperty emailaddresses

Set-UnifiedGroup -Identity BankingTeam -EmailAddresses @{Remove=""}
Get-UnifiedGroup -Identity BankingTeam | select -ExpandProperty emailaddresses

Note: Don’t try to update the SPO proxy address for groups. These addresses are used for internal links with SharePoint Online.

The same syntax can be used to add a new SMTP proxy address or MOERA address to a group. These commands create two new proxy addresses, the latter being a MOERA address.

Set-UnifiedGroup -Identity BankingTeam -EmailAddresses @{Add=""}
Set-UnifiedGroup -Identity BankingTeam -EmailAddresses @{Add=""}

To set a new primary address, run Set-UnifiedGroup -PrimarySmtpAddress and select one of the proxies already present for the group:

Set-UnifiedGroup -Identity BankingTeam -PrimarySmtpAddress

Restrictions in SMTP Address Assignment

You can’t remove the primary SMTP address of a group without reassigning primary status to another address first. Also, you can’t remove the MOERA address from a group (unless another exists). MOERA stands for Microsoft Online Email Routing Address. It is an SMTP proxy address from the tenant’s service domain (the one that looks like

In the past, all Microsoft 365 groups only had MOERA addresses. This situation persisted until Microsoft introduced support for email address policies for groups, a capability which allows administrators to dictate that the email addresses assigned to new groups come from a selected domain. Even if email address policies are in force, Exchange Online makes sure that new groups receive a MOERA SMTP proxy address.

Administrators can only remove a MOERA address from a group if another MOERA address is present in the set of proxy addresses for the group. In other words, before attempting to remove a MOERA address from a group, assign another to take its place. If you don’t, Exchange Online signals the error:

“There should be atleast one MOERA in Email Addresses.”

And yes, there’s no space between at and least in the error message.

Be Careful

Before you rush out to reclaim addresses, remember why SMTP proxy addresses exist. If you remove an address from Object A and assign it to Object B, any email sent to that address will be delivered to Object B. This might not be what you want to happen. Keeping old proxy addresses in the set assigned to mail-enabled objects allows those objects to continue receiving email for old addresses after updates to the primary SMTP address or MOERA address.

Retaining old proxy addresses might not be so important for a Microsoft 365 group because most of the traffic to group mailboxes is typically internal, but it is for recipients which receive a higher volume of external email such as user and shared mailboxes.

Learn more about how the Office 365 applications really work on an ongoing basis by subscribing to the Office 365 for IT Pros eBook. Our monthly updates keep subscribers informed about what’s important across the Office 365 ecosystem.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.