Change NS in Azure domains

Trezona 1 Reputation point

try use

I want to specify their NS servers, but the example above, I can not do because of the lack of links to Advanced Domain Management. And when I try to go and restore access says that there is no known error, try again later. And then it says you have exhausted 10 attempts... How do I change the NS of the domain ?



Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
6,039 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Ryan Hill 22,751 Reputation points Microsoft Employee

    Hi @Trezona ,

    Access to the Advanced Management Portal has been removed for Pay-As-You-Go subscriptions. Therefore, you will have to transfer you domain out of Azure in order to change NS servers. Managing an App Service Domain has a step-by-step procedure for performing this action through the Management REST API. Essentially, you will use one of the following commands to get an authorization code that you will then use at your preferred registrar.

    • Using Azure CLI: az rest --method PUT --uri '{subId}/resourceGroups/{rgName}/providers/Microsoft.DomainRegistration/domains/{domainName}/transferOut?api-version=2021-02-01'
    • Using PowerShell: Invoke-AzRestMethod -Path "/subscriptions/{subId}/resourcegroups/{rename}/providers/Microsoft.DomainRegistration/domains/{domainName}/transferout?api-version=2021-02-01" -Method PUT

    Do note if you recently purchased your domain, transferred it, or updated the contact information, you will not be able to transfer for 60 days. If run into any issues or need additional assistance, please follow directions provided by @SnehaAgrawal-MSFT .

    1 person found this answer helpful.
    0 comments No comments

  2. Andriy Bilous 10,381 Reputation points MVP

    Hello @Trezona

    The NS record set at the zone apex is automatically created with each DNS zone. It contains the names of the Azure DNS name servers assigned to the zone.
    You may add more name servers to this NS record set, to support cohosting domains with more than one DNS provider. You can also modify the TTL and metadata for this record set. However, you can't remove or modify the pre-populated Azure DNS name servers.

    If you want to Transfer domain out of Azure (not a registrar) to another registrar, it is supported and you may currently do so via API and PowerShell. You will need to get an authorization code which you can take to the registrar of choice to proceed with transferring out of your domain.

    Getting authorization code with Powershell
    There currently is no first class Powershell support for domain transfer out. However, you can use the following call below to get your authorization code:

    Invoke-AzRestMethod -Path "/subscriptions/<SUBSCRIPTION-ID>/resourceGroups/<RESOURCE-GROUP-NAME>/providers/Microsoft.DomainRegistration/domains/<DOMAIN-NAME>/transferout?api-version=2021-02-01" -Method PUT  

    Refer to the “authCode” value without the double quotes (“). This will be the authorization code you will need to provide the new domain registrar to transfer your domain out.