How to add a Custom Domain Name in Azure Active Directory

Introduction

 
In this post, we are going to see how to add a custom domain name in the Azure Active Directory (Azure AD) and how to set it as the primary Active Directory
 
The Azure AD tenant should come with a username.onmicrosoft.com initial domain.
 
By adding our own custom domain for our company, we can use it for company purposes such as user authentication (for example, if we add the custom domain name, we can create a user under the active directory such as [email protected]).
 

How to add a custom domain as an active directory in Azure AD

 
Go to the Azure AD service tenant in Azure portal -> on the left side, click Custom Domain Names.  
 
image1 
 
Click + Add Custom Domain 
 
image2 
 
On the right side, you should see the option to add the domain. In that custom domain name, add your domain name (for example, azure.contoso.org)
 
image3 
 
After adding the domain you can add the record sets for verifying the added domain. Copy the TXT record in the Destination or that points to the address text box
 
image4 
 
Go to your Domain Register (Go-Daddy or Azure DNS) vendor website and paste the copied TXT record in the record set creation area. (For example, I have added to AWS Route 53) 
 
image6 
 
After adding the record set, you can see that the record set has been saved in your Domain registered website
 
image6 
 
After adding the MX record in your registrar -> click Verify. Azure will verify that the MX record for our custom domain is available or not.
 
image7 
 
If Verification has completed successfully you can see the below screen will get the notification under the bell icon.
 
image8 
 
If you want to make it your primary directory, click 'Make Primary'
 
image9 
 
Click 'Yes' to make it your primary
 
image10 
 
Now you can see the domain name under the Custom Domains Tenant
 
image11