1
votes

I am newbie in web hosting. I have a domain name on GoDaddy www.mydomain.com. My web app is hosted on Azure App Service myapp.azurewebsites.net.

Now, I have configured my GoDaddy domain to point to azure web app. Azure app service is configured to accept request from www.mydomain.com, so anyone accessing my domain www.mydomain.com can see the app hosted on azure. This thing is working fine.

For example, I enter a URL www.mydomain.com, I get the expected result - web app hosted on azure with the www.mydomain.com URL in browser. The issue is, if I enter only subdomain name i.e. mydomain.com - without WWW prefix, I get the web app running on azure, but the URL gets replaced by azure app service URL myapp.azurewebsites.net.

What could be wrong here? My domain is configured for CNAME, and Azure App is also configured to accept custom domain with CNAME. Should I use A Record settings so that if I enter mydomain.com it gets replaced by www.mydomain.com instead of myapp.azurewebsites.net?

Thanks in advance!

1

1 Answers

0
votes

As per the documentation , it is recommended that you use a CNAME for all custom DNS names except a root domain (for example, contoso.com). You can also add/register your url without the "www." prefix, to set up another record in order for Azure to verify.

For more details, refer to the blog post in case if you haven’t checked earlier.