Renew a Free SSL Certificate Automatically
To renew a free SSL certificate automatically, you need three parts: an ACME client such as Certbot, acme.sh or Caddy that requests the new certificate, a scheduler that runs it, and a reload step that makes your server use the new files. Miss any one and you get an outage on expiry day. Let's Encrypt certificates last 90 days now, 64 days from 10 February 2027 and 45 days from 16 February 2028 (Let's Encrypt announcement).
Renew a free SSL certificate automatically with Certbot
Certbot packages from most Linux distributions install a systemd timer or cron entry on their own. Confirm it exists and test the process:
systemctl list-timers | grep certbot
sudo certbot certificates
sudo certbot renew --dry-runThe dry run uses the CA's staging system, so it does not use up real issuance limits. Certbot renews only certificates that are due and skips the others. Since Certbot 4.0.0, that means less than a third of the lifetime is left, which is 30 days on a 90-day certificate, about 21 on a 64-day one and 15 on a 45-day one (Certbot docs). Older versions used a fixed 30 days, which no longer fits shorter lifetimes. For a full walkthrough see automating renewal with Certbot.
Reload the server after renewal
New files on disk do nothing until the web server reloads. Add a deploy hook, which runs only when a certificate was renewed:
sudo certbot renew --deploy-hook "systemctl reload nginx"Or place a script in /etc/letsencrypt/renewal-hooks/deploy/. Certbot saves hooks used at issuance in the renewal config, so check the file under /etc/letsencrypt/renewal/ afterwards.
Renew a free SSL certificate automatically with acme.sh
acme.sh is a shell client that installs its own cron job. It can install the certificate and reload the server for you:
acme.sh --issue -d example.com -w /var/www/example
acme.sh --install-cert -d example.com \
--key-file /etc/ssl/example/key.pem \
--fullchain-file /etc/ssl/example/fullchain.pem \
--reloadcmd "systemctl reload nginx"The reload command is stored and used on every renewal.
Option 3: Servers with built-in ACME
Caddy obtains and renews certificates by itself with no cron job at all. If you can switch to it, much of this article becomes unnecessary. See automatic HTTPS with Caddy.
Option 4: Managed hosting and CDNs
Hosts, control panels and CDNs that issue free certificates renew them for you. You still need valid DNS and no blocking rules, but you do not run a client. Check your provider's docs for how they notify you of failures.
Comparison
| Method | Scheduler | Reload handled by | Best for |
|---|---|---|---|
| Certbot | systemd timer or cron | Deploy hook | Common Linux servers |
| acme.sh | Its own cron entry | --reloadcmd | Lightweight setups, many DNS plugins |
| Caddy | Built in | Built in | New projects |
| Host or CDN | Provider | Provider | Shared hosting, managed sites |
Why renewals fail
- Port 80 closed or a redirect blocks the challenge path.
- DNS changed, for example a new AAAA record or a moved nameserver.
- A DNS API token expired, so DNS-01 cannot add its record.
- The timer was disabled in an upgrade or the container was rebuilt without it.
- The server was never reloaded.
When it does fail, see fixing Certbot renewal errors and fixing a failed renewal.
Add monitoring as a second layer
Do not trust the scheduler alone. An outside check of the served certificate catches cases where renewal succeeded on disk but the server still serves the old file. This one-liner prints the expiry the world sees:
echo | openssl s_client -connect example.com:443 \
-servername example.com 2>/dev/null | \
openssl x509 -noout -enddateSet an alert for when fewer than 14 days remain. Our expiration alerts guide shows several ways. Do not rely on CA reminder emails: Let's Encrypt stopped sending expiration emails on 4 June 2025 (Let's Encrypt announcement).
Checklist
- Confirm the renewal timer or cron entry exists.
- Run a dry run and read the output.
- Add a reload hook and prove it works.
- Open ports and DNS as the challenge needs.
- Add an outside expiry alert.
Key takeaways
- Renewal needs a client, a scheduler and a reload step.
- Test with a dry run and confirm the served certificate changes.
- Monitor expiry from outside as a backup.
- Review the setup whenever you change hosts, DNS or firewall rules.
Related reading: automating Let's Encrypt renewal for 64-day certificates and renewing a Let's Encrypt certificate.
Frequently Asked Questions
When does Certbot renew a certificate?
Since Certbot 4.0.0, when less than a third of the lifetime remains: 30 days on a 90-day certificate, about 21 on a 64-day one and 15 on a 45-day one (Certbot docs). Older versions used a fixed 30 days.
How do I know automatic renewal is working?
Run certbot renew --dry-run, check expiry dates with certbot certificates, and confirm the certificate your server serves with an outside check. New files on disk do nothing until the server reloads.
Will I get an email if renewal fails?
Not from Let's Encrypt. It stopped sending expiration emails on 4 June 2025 (Let's Encrypt announcement). Set up an outside expiry alert instead.
✅ Post-Installation Verification & SEO Checklist
After applying the steps above, run through this 5-point checklist to prevent browser warnings and protect your Google SEO rankings:
- Verify full CA chain trust and TLS 1.3 support using our Live SSL Checker.
- Scan for Mixed Content HTTP links and check HSTS/CSP headers on Security Headers Checker.
- Enforce a permanent 301 HTTP-to-HTTPS redirect with our HTTPS Redirect Generator.
- Confirm both root and
wwwversions resolve cleanly to one canonical HTTPS URL. - Verify your HTTPS property and
sitemap.xmlinside Google Search Console and Bing Webmaster Tools.