Guides · HTTPS and certificate

Certificate expiry

One of the checks in every audibot report. This page says exactly what audibot reads, what passes, and how to fix it.

What audibot checks

The expiry date of the certificate on the HTTPS connection, counted in whole days from the time of the audit.

Why it matters

When a certificate lapses, every visitor gets a full-page warning until someone notices and renews it by hand. A certificate this close to expiry usually means the automation has failed silently.

How do I check when my SSL certificate expires and automate renewal?

Renew now, then find out why automatic renewal did not run: a disabled timer, a changed web root, a firewall blocking the HTTP-01 challenge, or a DNS API token that expired.

Check the expiry date

echo | openssl s_client -connect example.com:443 -servername example.com 2>/dev/null \
  | openssl x509 -noout -enddate

Certbot: is the timer running, and would renewal work?

systemctl list-timers | grep certbot
sudo certbot renew --dry-run

Reload the server after renewal

sudo certbot renew --deploy-hook "systemctl reload nginx"

Related tools

Other checks in HTTPS and certificate

HTTPS and certificate in the methodology ·All guides

This check is one step of the website launch checklist.

Check your site

audibot runs this check and every other one in a single audit, and publishes the report with a recommendation for each finding.