I can't add a custom sub domain to Azure Blob Storage to delivery my static website

Polo 0 Reputation points

Hi there!

I use Azure Blob Storage to store and delivery my assets in a static website. This perfectly work with the static endpoint given by Azure.

I want to link my domain to my $web container, but I can't, I can't see "Blob service" category in the menu (so I can't open on the custom domain tab).

By the way, Secure transfer required in Settings > Configuration is enabled.

If I add my Azure static endpoint directly to my DNS zone on Cloudflare as a CNAME record, I get the error "The request URI is invalid" (HttpStatusCode: 400, ErrorCode: InvalidUri). Automatic HTTP to HTTPS redirection on Cloudflare is enabled, and the traffic is proxied.

Here's what I want to see:User's image

Here's what I have:

User's image

Can you please help me?

Thank you in advance for your answer.

Azure Storage Accounts
Azure Storage Accounts
Globally unique resources that provide access to data management services and serve as the parent namespace for the services.
2,312 questions
Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
2,094 questions
{count} votes

2 answers

Sort by: Most helpful
  1. deherman-MSFT 30,466 Reputation points Microsoft Employee


    It seems you were able to resolve this issue via the support case we provided. If you could Accept Answer that would help future community members. Here is a summary of that case:

    Initially you were Unable to add custom domain from the portal. For which the required document and steps with screenshot was shared with you.


    Also, you were getting error while adding a custom domain to Azure Blob Storage to deliver the static website and through call and screen sharing session solution was provided and the error was resolved.


    Then when you were adding Azure static endpoint directly to your DNS zone on Cloudflare as a CNAME record, you were getting error, gave resolution and it worked.
    Also provided Cloudflare proxy, and you could use the edge certificate to have HTTPS without having any errors and subdomain problem was solved.

    If you still have questions, please let us know in the "comments" and we would be happy to help you. Comment is the fastest way of notifying the experts.

    If the answer has been helpful, we appreciate hearing from you and would love to help others who may have the same question. Accepting answers helps increase visibility of this question for other members of the Microsoft Q&A community.

    Thank you for helping to improve Microsoft Q&A!

    User's image

  2. Polo 0 Reputation points


    after a lot of research by the Azure team and myself, it is possible to link a subdomain with a hierarchical namespace.

    However, once the flat namespace storage account has been transformed into a hierarchical namespace, the "Blob service" menu no longer appears, and therefore the "Custom domain" item no longer appears either.

    Adding a custom domain can only be done from the Azure bash terminal, with the command az storage account update --resource-group NAME_OF_RESOURCE_GROUP --name NAME_OF_THE_STORAGE_ACCOUNT --custom-domain sub.example.com --use-subdomain false.

    If you want to use a proxy for your subdomain, this is possible, but it must be activated after the subdomain linked to the storage account.

    Note that initially, you'll get an error giving you the 2 possible endpoints to add to your domain's DNS zone. Take the desired endpoint, add it, then run the command again. Your subdomain is now linked to your hierarchical namespace storage account!

    I hope that my answer can enlighten future people who have encountered the same problem as me!

    0 comments No comments