Fix guides

Vercel custom domain shows Invalid Configuration or no HTTPS: fix the DNS and the certificate

Your app works on its vercel.app URL, but the custom domain says Invalid Configuration, does not resolve, or has no valid HTTPS certificate. How to check the records Vercel actually wants, clean up old ones, and get the certificate issued.

Free · no card

Paste your error. Get a free diagnosis by email.

Tell us what broke and we’ll email you a short diagnosis: the likely cause and what to try first. Usually within a day.

No passwords or secret keys, please. We only use your email to reply about this.

What you are seeing

Why it happens

  1. The A record points at an address copied from an old tutorial or another project. Vercel's docs say each project shows its own recommended values: some show 76.76.21.21, newer projects can show an address such as 216.198.79.1, and the wrong one can leave the domain flagged.
  2. Old records are still there: the registrar's parking-page A records or an AAAA record. Vercel does not support IPv6 for domains using external DNS, so leftover records send some visitors elsewhere.
  3. Records were added at the wrong place. DNS is only read from the nameservers your registrar lists, so records at your old host do nothing after you switch nameservers, and the reverse.
  4. The Name field has the full hostname. The name should be the prefix (www, or @ for the apex); some providers append your domain to whatever you type.
  5. Only one of example.com and www.example.com was added to the project.
  6. A proxy in front of Vercel (for example Cloudflare's orange cloud) intercepts /.well-known/acme-challenge/, so Let's Encrypt cannot validate. Cloudflare's Flexible SSL mode is a common cause of redirect loops, per Vercel's docs.
  7. A CAA record that does not allow Let's Encrypt, or a stale _acme-challenge record from a previous host, blocks the certificate.
  8. Changes have not propagated yet, or one network's DNS filter blocks the domain, so it works on mobile data but not on office Wi-Fi.

How to fix it

1. Copy the exact records Vercel wants

Open the project, then Settings, then Domains. Add both example.com and www.example.com if they are not there, and copy the A value and the CNAME target shown for each. Use those values, not ones from a guide, another project, or an AI chat.

2. See what DNS returns right now

dig NS example.com +short          # which provider is authoritative
dig A example.com +short           # should match the A value from step 1
dig AAAA example.com +short        # should be empty
dig CNAME www.example.com +short   # should match the CNAME target from step 1

3. Set the records at the provider that answers for the domain

Type   Name   Value
A      @      <the A value shown in Settings > Domains>
CNAME  www    <the CNAME target shown for www, e.g. d1d4fc829fe7bc7c.vercel-dns-017.com>

Delete every other A and AAAA record on @ and www (parking pages, old hosts).
Then set one of the two domains to redirect to the other in Settings > Domains.

4. If you use Cloudflare

Set the records that point at Vercel to DNS only (grey cloud) until the certificate is issued. If you keep the proxy, do not use Flexible SSL mode, and make sure /.well-known/acme-challenge/ reaches Vercel without caching, redirects, or rules.

5. Check that the certificate challenge can reach Vercel

curl -sS -D - -o /dev/null http://example.com/.well-known/acme-challenge/test-token
# expect a 404 from Vercel (server: Vercel), not a redirect, a 403, or another host

dig CAA example.com +noall +answer
# if this lists issuers, one must be: 0 issue "letsencrypt.org"

dig TXT _acme-challenge.example.com +short
# leftovers from an old host can block validation; check before deleting

6. Refresh, wait out the TTL, and test from another network

Click Refresh on the domain in Settings > Domains. Record changes usually show up within the old record's TTL; nameserver changes can take 24 to 48 hours per Vercel's docs. If it works on your phone's mobile data but not on one Wi-Fi network, that network's DNS or filtering is the problem, not Vercel.

How to know it is fixed

Settings > Domains shows both domains as valid with a certificate, dig returns exactly the values Vercel shows, and curl -IL https://example.com finishes over HTTPS at your primary domain with a 200. Open both the apex and www in a private window and on mobile data. Sources: Vercel: Troubleshooting domains, Vercel: Adding and configuring a custom domain, and Vercel: Working with SSL certificates. Related: apex vs www redirects breaking Stripe webhooks and auth redirect URLs after a domain change.