Multi-domain support for Office 365 groups - Admin help

Some large organizations use separate email domains to segment different parts of their businesses. As an admin, you can specify the domain to be used when users in your organization create Office 365 groups.

If your organization requires users to create their groups in domains other than the default accepted domain of your organization, you can do this by configuring email address policies (EAPs) using PowerShell.

Connect to Exchange PowerShell

Before you can run the PowerShell cmdlets, you have to download and install a module that will let you talk to your Office 365 organization. Check out Connect to Exchange Online using remote PowerShell.

Configuring email address policies

For example, your organization’s main domain is but as your organization’s default accepted domain is, Office 365 groups will get created in (e.g. You also have sub-domains configured in your organization, that you want Office 365 groups to get created in. For example:

  • for students

  • for faculty members

Note: EAPs are evaluated in the order of priority. A value of 1 means the highest priority. Once an EAP matches, no further EAP is evaluated and addresses that gets stamped on the Office 365 group are as per the matched EAP. If no EAPs match the specified criteria, then the Office 365 group gets provisioned in the organization’s default accepted domain. Check out Manage accepted domains in Exchange Online for details on how to add an accepted domain.

Scenario 1

The following example shows you how to provision all Office 365 groups in your organization in the domain.

New-EmailAddressPolicy -Name Groups -IncludeUnifiedGroupRecipients -EnabledEmailAddressTemplates "" -Priority 1

Scenario 2

You want to control what sub-domains Office 365 groups are created in. You want:

  • Office 365 groups created by students (users which have Department set to Students) in the domain

    New-EmailAddressPolicy -Name StudentsGroups -IncludeUnifiedGroupRecipients -EnabledEmailAddressTemplates "","” -ManagedByFilter {Department -eq 'Students'} -Priority 1
  • Office 365 groups created by faculty members (users which have Department set to Faculty or email address contains in the domain

    New-EmailAddressPolicy -Name FacultyGroups -IncludeUnifiedGroupRecipients -EnabledEmailAddressTemplates "","” -ManagedByFilter {Department -eq 'Faculty' -or EmailAddresses -like "**"} -Priority 2
  • All other users in the domain

    New-EmailAddressPolicy -Name OtherGroups -IncludeUnifiedGroupRecipients -EnabledPrimarySMTPAddressTemplates "" -Priority 3

Change email address policies

To change the priority or email address templates for an existing EAP, use the Set-EmailAddressPolicy cmdlet.

Set-EmailAddressPolicy -Name StudentsGroups -EnabledEmailAddressTemplates "","”, “” ManagedByFilter {Department -eq 'Students'} -Priority 2

Changing an EAP has no impact on the groups that have already been provisioned.

Delete email address policies

To delete an EAP, use the Remove-EmailAddressPolicy cmdlet.

Remove-EmailAddressPolicy -Name StudentsGroups

Changing an EAP has no impact on the groups that have already been provisioned.

Hybrid requirements

If your organization is configured in a hybrid scenario, check out Configure Office 365 Groups with on-premises Exchange hybrid to make sure your organization meets the requirements for creating Office 365 groups.

Additional info

There are a few things to know about using email address policies for Office 365 groups:

  • Group creation performance depends on the number of EAPs configured in your organization.

  • Users will not be able to modify domains when they create Office 365 groups. Only admins can specify the domain in which the group can be created.

  • Group of users is determined using the standard queries (User properties) that are already available. Check out Filterable properties for the -RecipientFilter parameter for supported filterable pproperties.

  • If you don’t configure any EAPs for groups, then the default accepted domain is selected for group creation.

  • If you remove an accepted domain, you should update the EAPs first, otherwise, group provisioning will be impacted.

  • A maximum limit of 100 email address policies can be configured for an organization.

Expand your skills
Explore training
Get new features first
Join Office Insiders

Was this information helpful?

Thank you for your feedback!

Thank you for your feedback! It sounds like it might be helpful to connect you to one of our Office support agents.