Custom Domains For Web Pages Hosted On Azure App Service

Introduction 

 
If you are thinking of creating your own website, you have probably heard of the word "domain," but do you know what it means?
 
The domain is a name that identifies a website on the Internet. Its fundamental purpose (along with the Domain Name System (DNS)) is to translate IP addresses into terms that are easier to memorize and find. That is, more simply, the domain corresponds to your Page's link. For the case of this article, our tutorial is under the domain c-sharpcorner.com. Choosing a good domain is very important, as it will be accessible to our website. This, preferably, should be formed with the name of your company, and if you want with the category of it, as it will help you to position your website more easily.
 
Currently, there are a lot of services that provide domains on the Internet, in this case, we will learn how to buy a domain in Azure and associate it with a web page that we have hosted through the Azure App Service resource.
 

Buy the domain

 
In the Azure portal, we need to find the App Service Domains resource and then click Add to register a new domain.
 
To purchase the new domain, we need to provide the following information,
 
  • Domain name: In the Search domain box, we need to enter the domain name we want to purchase. Suggested available domains are displayed just below the text box. In this case, you can select one or more domains to purchase later.
  • The Azure subscription. This will be the subscription with which we will purchase the domain.
  • The contact information of the person responsible for the domain.
  • Accept the legal terms of service. The cost of the domain is detailed in this section. This value will be deducted from available Azure credits.
 
Finally, we click on Create. The domain acquisition process takes 1-3 minutes to complete.
 
 
Assign the new domain to a page hosted on Azure App Services.
 
Change the resource plan
 
As a first point, we should be aware that our app in Azure App Service must have a plan that allows you to associate custom domains. To do this, within the App Service menu bar in the Settings section, we go to: Scale up (App Service plan)
 
 
In this section, we need to select a payment plan that allows you to associate custom domains. After performing this process, we save the changes to the Apply button.
 
Add the custom domain
 
Then, within the same Configuration section in the App Service, we go to the Custom domains option.
 
Here, we click Add custom domain.
 
 
The resource will then ask us to specify the custom domain.
 
 
Then we click Add custom domain, and with this, we would already have associated our new custom domain with the web page hosted in the Azure App Service.
 
 
The result...
 
From now on, we can access our website with the domain created and also with the .azurewebsites.net address that was previously had.
 
 
What's next?
 
With these steps, we learned how to associate a new domain with an existing web page hosted on a resource with Azure App Service.
 
Want to learn more? Here are some tutorials that could be of great use to you:
See you on Twitter!! :)


Similar Articles