When you try to remove a domain from Microsoft Office 365, you experience one or both of the following symptoms:
- When you try to remove the domain through the Office 365 portal, you receive the following error message:
Domain is the primary/default domain.
- When you try to remove the domain by using Windows PowerShell, you receive the following error message:
Remove-MsolDomain : You cannot delete the default domain. Use the Set-MsolDomain cmdlet to set another domain as the default domain before you delete this domain.
At line:1 char:18
+ Remove-MsolDomain <<<< -DomainName <DomainName>
+ CategoryInfo : OperationStopped: (:) [Remove-MsolDomain], MicrosoftOnlineException
+ FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.DefaultDomainDeletionException,Microsoft.Online.Administration.Automation.RemoveDomain
This issue occurs if the domain is the primary or default domain.
To fix this issue, set the primary domain by editing the company profile. To do this, follow these steps:
- Sign in to the Office 365 portal (https://portal.microsoftonline.com
) as a global administrator.
- Click Admin. Then, if the Office 365 option is available, select this option.
- The name of your company is displayed near the top of the page. The name of your company acts as a link to your company's profile.
Click the name of your company to see the profile.
- In the profile window, click Edit.
- In the Default domain box, change the domain, and then click OK.
For more information, see the following Microsoft Knowledge Base article:
You get an error message when you try to remove a domain from Office 365
Still need help? Go to the Office 365 Community
Article ID: 2787250 - Last Review: October 25, 2013 - Revision: 9.0
- Microsoft Office 365 for enterprises (pre-upgrade)
- Microsoft Office 365 for education (pre-upgrade)
- Microsoft Office 365 for small businesses (pre-upgrade)
- Microsoft Office 365
|o365 o365022013 after upgrade o365062011 pre-upgrade o365e o365p o365a o365m KB2787250|