Knowledgebase

Issuing Certificates When a Domain Is Behind a Proxy Print

  • sslcertificateshttps, ssl, domain, cloudflare, dns, troubleshooting, domainrenewal, renewal, cpanel, nameservers
  • 0

Getting AutoSSL to work with Cloudflare in place.

THE PROBLEM

AutoSSL validates by retrieving a file from your site. With the record proxied, that request reaches Cloudflare rather than our server.

THE STRAIGHTFORWARD FIX

  1. Set the A record for the domain and www to DNS-only in Cloudflare.
  2. Wait a few minutes for the change to take effect.
  3. Run AutoSSL in cPanel.
  4. Confirm the certificate issued.
  5. Re-enable proxying.

Renewal faces the same issue. If renewals fail repeatedly, either leave the records DNS-only, or use a Cloudflare origin certificate instead.

AN ALTERNATIVE

Create a Cloudflare page rule or configuration that allows the /.well-known/acme-challenge/ path through without interference. This permits validation while proxying continues.

CHECKING WHETHER THIS IS YOUR PROBLEM

If AutoSSL fails and your nameservers point at Cloudflare, this is almost certainly the cause.

MAIL RECORDS

Always DNS-only, which means mail certificates issue normally.


Was this answer helpful?
Back

Are you happy with your experience? Leave us a review on Trustpilot.


Trustpilot