Issue with creating custom domain in Static Web App

Jonas Wilkening 40 Reputation points
2026-02-05T09:06:28.0133333+00:00

Attempting to create a custom domain is stuck in validating forever. there is no indication of why it is not working.

Tried different ways of creating the cusotm domain (via azure portal & powershell) and validation (CNAM & TXT) already.

Please assist, thanks!

Azure Static Web Apps
Azure Static Web Apps

An Azure service that provides streamlined full-stack web app development.


Answer accepted by question author
Jonas Wilkening 96 Reputation points
2026-02-10T13:18:43.61+00:00

The Problem were missing CAA records for digicert. Thanks for to @Praneeth Maddali for assisting and pointing that out.

Was this answer helpful?

2 people found this answer helpful.

Answer accepted by question author
Praneeth Maddali 12,505 Reputation points Microsoft External Staff Moderator
2026-02-10T13:22:38.72+00:00

Hi @Jonas Wilkening

Thanks for the detailed tests so far. Based on the behavior you’re seeing (TXT record correct but validation still failing, and CNAME returning “CNAME record is invalid”), this matches a known issue in Azure Static Web Apps: the domain cannot be validated unless DigiCert is explicitly allowed as a certificate issuer.

Azure uses DigiCert to issue the automatic SSL certificate. If your DNS zone does not include a CAA record for DigiCert, validation can hang indefinitely.

Please add the following DNS record at your DNS provider:

Type: CAA Name: @ Value: 0 issue "digicert.com" TTL: 300

If you already have a CAA record (for example only Let’s Encrypt), simply add an additional entry — multiple CAA records are supported.

After adding the record

  1. Remove the custom domain from your Static Web App
  2. Wait ~5–10 minutes
  3. Re‑add the custom domain using TXT validation
  4. Click Refresh a few times — validation should complete within a few minutes

This exact fix has resolved the same issue for multiple customers where TXT and CNAME validation kept failing even though DNS was correct.

 Please do not forget to click "Accept the answer” and Yes, this can be beneficial to other community members.

If you have any other questions, let me know in the "comments" and I would be happy to help you

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

1 additional answer

Sort by: Most helpful
  1. TP 162.1K Reputation points Volunteer Moderator
    2026-02-05T09:11:31.1833333+00:00

    Hi Jonas,

    UPDATE: I queried DNS and your TXT record appears correct. Sometimes the process gets stuck even though you have things correct. Please try below steps:

    1. Remove existing TXT record, wait 5 minutes (for TTL to expire)
    2. Create CNAME with TTL 300 (5 minutes), use nslookup to verify it exists from your client PC. If not, keep trying nslookup until it shows up. Depending on your provider, the delay may be seconds or several minutes
    3. Delete your custom domain from Static Web App, wait for it to complete (usually only seconds)
    4. Add -- Custom domain on other DNS, enter your domain, Next, select TXT from dropdown, click Generate code. When code shows up, create new TXT record in your DNS, copy/paste in the value, TTL 300. Verify it exists using nslookup, when it shows up click Close button
    5. On the list of custom domains it should Validating. If you want you can View details and then click Refresh button in the flyout window, or you can periodically click Refresh on the list of custom domains

    In my experience it typically takes 10 minutes or less for the validation to complete and certificate to be issued. If it hasn't finished within 15 minutes or so I would delete and try again. I just did a new custom domain and it took about 8 minutes.

    Please click Accept Answer and upvote if the above was helpful.

    Thanks.

    -TP

    Was this answer helpful?

    1 person found this answer helpful.

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.