Skip to content

TechDirectArchive

Hands-on IT, Cloud, Security, Veeam & DevOps

  • Home
  • About
  • Advertise With US
  • Reviews
  • Contact
  • Toggle search form

Delete Azure Tenant: Remove Custom Domain from Entra ID

Posted on 19/11/202419/11/2024 IT Expert By IT Expert No Comments on Delete Azure Tenant: Remove Custom Domain from Entra ID
  1. Home
  2. AWS/Azure/OpenShift
  3. Delete Azure Tenant: Remove Custom Domain from Entra ID
Remove Custom Domain from Entra ID and Azure tenant

In this article, we shall discuss the steps to “Delete Azure Tenant: Remove Custom Domain from Entra ID”. To delete an Azure account and deregister a custom domain associated with Entra ID, the below steps must be followed carefully. Please see How to deactivate and reactivate a Slack user, “Microsoft Azure Active Directory: How to setup Azure AD Tenant“, and how to “Register Devices to Intune and EntraID Using Company Portal“.

Note that deleting your Azure account can be irreversible, so ensure all critical data is backed up. When an tenant) is deleted in Microsoft Entra ID, all resources in the organisation are also deleted. Prepare your organisation by minimising its associated resources before you delete.

Why Delete Azure Tenants?

There are numerous reasons why you would want to delete an Azure Tenant. One of the reasons could be that you have claimed an Office 365 license in a wrong tenant which was my case.

  • Another reason could be businesses consolidating multiple tenants or migrate to a different tenant for better resource and user management. A typical example of this is, merging two organisations or moving resources to a central tenant.
  • If a tenant was created for testing, development, or a temporary project, it may no longer be needed once the project concludes. While Azure Active Directory itself might not have direct costs, associated subscriptions, applications, and licenses can incur charges. Deleting unused tenants helps avoid unnecessary expenses.
  • When a tenant is no longer required, keeping it active might pose security or compliance risks especially if it is not actively monitored. Therefore, this was also a reason for the deletion in my environment.

Most importantly in my case, custom domains associated with a tenant cannot be used in another tenant unless removed. Therefore, since the tenant will NEVER be used anymore, it was sufficient to have it deleted.

Please see how to Move Azure Resources between Subscriptions, and “How to add and verify a custom domain name to Azure Active Directory“.

Remove Custom Domain from Entra ID (Azure Active Directory)

First, we will have to dissociate the custom domain from the Tenant. To do this, log in to the Azure Portal and navigate to Entra ID.

Ensure that no users, groups, or applications are using this domain; you may need to change them to the default onmicrosoft.com domain first by making this a primary domain.

In the left panel, select Custom domain names. Choose the custom domain you want to remove.

custom domain

Now, let us make the onmicrosoft.com the default domain. The tenant is associated with a custom domain, which needs to be disassociated and deleted.

remove domain

Note: You will also need to cancel (delete) all Entra ID subscriptions before deleting your Tenant. Also, the associated user to the custom domain, and the resource groups need to be removed

Delete User

To delete a user, this is straight forward. To do this, log in to the Azure Portal and navigate to Entra ID and navigate to Users.

Select the account(s) and have them deleted.

Delete Dependcies relating to domain

User account to delete

delete user

Confirm user deletion

Confirm user deletion

User account removed.

user deleted

Switch Domain

Now that we have deleted all dependancies associated with the custom domain. We will proceed to make the default directory the primary domain.

make default domain primary

Confirm to make the domain the primary domain.

domain made primary

As you can see below, we have successfully made the onmicrosoft.com the primary domain.

Domain-name-switched

Click on Delete to remove the custom domain.

Delete Domain

Click on delete again. As you can see, we have met the delete requirement as well.

Delete custom domain

Custom domain successfully deleted.

domain removed

Please see how to Fix missing path and delete a Veeam Backup Repository, How to Install OpenSSL on Windows Computers, and how to Fix the Port used for the Virtualhost is not an Apache Listen Port.

Delete subscription

If you have an active or canceled Azure subscription associated with your Microsoft Entra tenant, you can’t delete the tenant.

After you cancel, billing is stopped immediately. After you cancel a subscription, your billing stops immediately. You can delete your subscription directly using the Azure portal seven days after you cancel it, when the Delete subscription option becomes available.

Once your subscription is deleted. Microsoft waits 30 to 90 days before permanently deleting your data in case you need to access it or reactivate your subscription

As you can see, we have got no subscriptions associated. You can’t delete an organization in Microsoft Entra ID until it passes several checks. These checks reduce the risk that deleting a Microsoft Entra organization negatively affects user access, such as the ability to sign in to Microsoft 365 or access resources in Azure.

But you could have dependencies from O365. You also have to check this, else you will never be able to delete the Tenant.

Remove any subscription if available

Delete Azure Tenant

To delete the Tenant, click on “Manage Tenants” as shown below

Manage tenant

As shown below, only one tenant is present, and it will be deleted for consolidation purposes.

delete tenant

As you can see below, I have not meet the prerequisites to have this tenant deleted.

I will work through the affected status and ensure all required actions are met.
tenant deletion failure

For the enterprise application (BingWebmasterTools), I will proceed to the blade and have it deleted. Also, for LinkedIn, I will have this deleted.

A few enterprise applications can’t be deleted in the Microsoft Entra admin center and might block you from deleting the tenant. Please use the PowerShell code to remove those applications as discussed in this Microsoft Guide.

deete big webmaster

Now, we are having issues with a license based subscripting and this related to O365.

Delete O365 subscription

Unassign Office 365 License

Navigate to the Office 365 Admin Center, and unassign the license

unassign license

You will also have to cancel the subscription as I wish t use this with another tenant.

cancel subscription

I will also delete it. This might not be the case for you.

delete and confirm subscrition deletion for 0365

Shortly, you will get an email stating that “Christian Eromosele submitted a request on November 14, 2024 to delete your Office 365 E3 EEA (no Teams) subscription. It is currently disabled and will be deleted on November 17, 2024. After your subscription is deleted, it can’t be recovered. If you’d like to reactivate it, you may do so until November 16, 2024. To reactivate your subscription: In the Microsoft 365 admin center, go to Billing > Your products. On the Your products page, find the subscription that you want to reactivate. In the Billing section of that subscription, select Reactivate now. Confirm or change your payment method, and then select Reactivate.

Below is the email received just for your information.

Subscriptin deleted

Note: According to the Microsoft documentation. After you’ve deleted a subscription in your organisation and 72 hours have elapsed, sign in to the Microsoft Entra admin center again. Confirm that no required actions or subscriptions are blocking your organisation deletion. You should be able to successfully delete your Microsoft Entra organization.

After the said hors has passed, you can see all checks have passed and I can now delete the Azure Tenant. Click on delete to delete the Tenant.

Delete Tenant

Account has been successfully scheduled for deletion.

Tenant scheduled for deletion

The Tenant is gone!

That is all you need to do to clean up tenants that are no longer useful or when you are transitioning away from Azure.

unable to access azure portal - something went wrong

I hope you found this article on “Delete Azure Tenant: Remove Custom Domain from Entra ID” very useful. Please feel to leave a comment below.

5/5 - (1 vote)

Thank you for reading this post. Kindly share it with others.

  • Share on X (Opens in new window) X
  • Share on Reddit (Opens in new window) Reddit
  • Share on LinkedIn (Opens in new window) LinkedIn
  • Share on Facebook (Opens in new window) Facebook
  • Share on Pinterest (Opens in new window) Pinterest
  • Share on Tumblr (Opens in new window) Tumblr
  • Share on Telegram (Opens in new window) Telegram
  • Share on WhatsApp (Opens in new window) WhatsApp
  • Share on Mastodon (Opens in new window) Mastodon
  • Share on Bluesky (Opens in new window) Bluesky
  • Share on Threads (Opens in new window) Threads
  • Share on Nextdoor (Opens in new window) Nextdoor
AWS/Azure/OpenShift Tags:Azure, Azure Active Directory, Azure AD, Azure AD Tenant, Domain

Post navigation

Previous Post: Fix missing path and delete a Veeam Backup Repository
Next Post: AADSTS50020: User from Identity Provider does not exist in Tenant

Related Posts

  • VBAWS comprehensive guide
    Deep Dive into Protecting AWS EC2, RDS Instances and VPC AWS/Azure/OpenShift
  • Setup FSx File System 1
    Create and mount FSx File System: Join EC2 instance to AWS Managed AD AWS/Azure/OpenShift
  • image 10
    How to use Microsoft SQL Server Management Studio to Export and Import your MsSQL database from Azure to local computer AWS/Azure/OpenShift
  • Opswork blog 1440x800 1
    Get Started with OpsWorks for Chef Automate AWS/Azure/OpenShift
  • adfs
    Guide on federating ADFS with Azure Active Directory AWS/Azure/OpenShift
  • Webp.net resizeimage 4
    Create a Service Fabric Cluster using the Azure Stack Hub portal and the CLI AWS/Azure/OpenShift

More Related Articles

VBAWS comprehensive guide Deep Dive into Protecting AWS EC2, RDS Instances and VPC AWS/Azure/OpenShift
Setup FSx File System 1 Create and mount FSx File System: Join EC2 instance to AWS Managed AD AWS/Azure/OpenShift
image 10 How to use Microsoft SQL Server Management Studio to Export and Import your MsSQL database from Azure to local computer AWS/Azure/OpenShift
Opswork blog 1440x800 1 Get Started with OpsWorks for Chef Automate AWS/Azure/OpenShift
adfs Guide on federating ADFS with Azure Active Directory AWS/Azure/OpenShift
Webp.net resizeimage 4 Create a Service Fabric Cluster using the Azure Stack Hub portal and the CLI AWS/Azure/OpenShift

Leave a Reply Cancel reply

You must be logged in to post a comment.

Microsoft MVP

VEEAMLEGEND

vexpert-badge-stars-5

Virtual Background

GoogleNews

Categories

veeaam100

Veeam Vanguard

  • Copilot Microsoft
    How to Disable Copilot in Windows and Microsoft Edge Windows
  • powershell
    How to install the Microsoft PSWindowsUpdate module silently Scripts
  • blue screen error during windows 10 upgrade thumbnail
    Replace a blue screen error with a blank screen for system errors Windows
  • update powershell
    Fix WDAC vulnerabilities by updating PowerShell Security | Vulnerability Scans and Assessment
  • Veeam Agent Error Fix
    Fixing AIX Veeam agent job startup delay issue Network | Monitoring
  • Microsoft365
    Microsoft 365 Backup: Why is it imperative to protect M365? Backup
  • sync
    AD Connect Sync Service Not Running: Start ADSync to Continue AWS/Azure/OpenShift
  • FTP
    How to install and configure an FTP Server on Windows Server Windows Server

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 1,801 other subscribers
  • RSS - Posts
  • RSS - Comments
  • About
  • Authors
  • Write for us
  • Advertise with us
  • General Terms and Conditions
  • Privacy policy
  • Feedly
  • Telegram
  • Youtube
  • Facebook
  • Instagram
  • LinkedIn
  • Tumblr
  • Pinterest
  • Twitter
  • mastodon

Tags

AWS Azure Bitlocker Microsoft Windows PowerShell WDS Windows 10 Windows 11 Windows Deployment Services Windows Server 2016

Copyright © 2025 TechDirectArchive

Loading Comments...

You must be logged in to post a comment.