What does 'NET::ERR_CERT_COMMON_NAME_INVALID' mean?
The server presented a valid certificate, but not for this hostname. A common case is www.example.com serving a cert issued only for example.com, or a host's default cert because the domain isn't attached to your project. Add the exact hostname (apex and www) to your hosting project so the certificate covers it.
Last updated 2026-11-25 · Reviewed by ProofForge
The exact error
Your connection is not private
Attackers might be trying to steal your information from www.example.com.
NET::ERR_CERT_COMMON_NAME_INVALIDWhy it happens
- Only the apex domain is added to the host, but DNS for
wwwpoints there too. - DNS points to a platform that serves its own default certificate for unknown domains.
- Old A records point at a previous server.
How to fix it
- Add both
example.comandwww.example.comto the hosting project, and redirect one to the other. - Remove stale A/AAAA/CNAME records so only the current host answers.
- Wait for the new certificate, then retest.
# which names does the served certificate cover?
openssl s_client -connect www.example.com:443 -servername www.example.com </dev/null 2>/dev/null \
| openssl x509 -noout -ext subjectAltNameCheck it's fixed
The certificate's Subject Alternative Name list includes the exact hostname, and the browser shows no warning.
Check your live app
A free, read-only public-surface scan. It cannot diagnose private sessions or every cause described above.
FAQ
Can visitors click through?
They can, but most won't, and it trains users to ignore real attacks. Fix the certificate.
Does it hurt SEO?
Yes. Crawlers and users can't load the page securely on that hostname.
Common name or SAN?
Browsers check the Subject Alternative Name list. The error name is historical.