Not able to delete a custom domain in front door

Akshay Chauhan 46 Reputation points

I have a custom domain associated with front end in azure front door which I am not able to delete. On deleting I get error
Failed to update the Front Door 'somename'. Error: Cannot delete frontend endpoint "somedomain" because it is still CNAMEd to front door "". Please remove the DNS CNAME records and try again. Why am I getting this error. How to resolve it?92222-tempsnip.png

Azure Front Door
Azure Front Door
An Azure service that provides a cloud content delivery network with threat protection.
575 questions
0 comments No comments
{count} vote

Accepted answer
  1. msrini-MSFT 9,251 Reputation points Microsoft Employee


    When you created the custom domain for the first time, you must have added a CNAME record in your registrar or in your Azure DNS which is still pointing to the Azure Front Door's FQDN. You need to first remove the CNAME which you have created. Then try to delete the AFD again.

    2 people found this answer helpful.

2 additional answers

Sort by: Most helpful
  1. Akshay Chauhan 6 Reputation points

    Microsoft has introduced this breaking change (11231). But it seems like it can be disabled by registering feature flag:

    az feature register --namespace Microsoft.Network --name BypassCnameCheckForCustomDomainDeletion
    1 person found this answer helpful.

  2. Lucas Luengo 1 Reputation point

    Me too. I think this happens when you have a wildcard subdomain.
    I checked several times and there is no CNAME binded to the endpoint I'm trying to delete.

    0 comments No comments