Choosing an ACME client affects more than the command used to request a certificate. It determines how validation is performed, where keys and certificates are stored, how renewals are scheduled, and what happens when your web server, DNS provider, or deployment process changes. This guide compares Certbot, acme.sh, and lego, then provides a practical way to select, monitor, and migrate between them.
Overview
Certbot, acme.sh, and lego can all automate certificates issued through the ACME protocol, including certificates from Let’s Encrypt. None is universally the “best” Let’s Encrypt client. The right choice depends on your operating system, web server, DNS provider, deployment model, and comfort with shell scripts or compiled binaries.
Certbot is often a good fit when you want an established tool with web-server integrations, distribution packages, and a guided workflow. It is especially convenient on a conventional Linux server running Apache or Nginx, provided the available package and plugins match your deployment.
acme.sh is a shell-based client that is attractive for minimal servers, users who want a lightweight installation, and environments where DNS-01 automation is central. Its configuration and command style are distinct from Certbot, so document its file locations and scheduled jobs rather than assuming the same layout.
lego is a Go-based ACME client distributed as a binary or used inside automation and container workflows. It can be a practical choice when you want a single executable, explicit command-line control, or integration with a Go-oriented deployment process.
The comparison below is a starting point, not a substitute for checking the current documentation for your operating system and DNS provider.
| Area | Certbot | acme.sh | lego |
|---|---|---|---|
| Typical installation | Operating-system package, Python environment, or container | Installer script or manually managed shell installation | Prebuilt binary, package, source build, or container |
| HTTP-01 | Supported, with web-server and standalone approaches | Supported, with webroot and standalone approaches | Supported, with webroot, standalone, and related challenge modes |
| DNS-01 and wildcards | Supported through compatible DNS plugins or manual workflows | Strong fit for DNS-01 and provider-specific DNS APIs | Supported through DNS-provider integrations and environment settings |
| Web-server hooks | Commonly handled through installers, deploy hooks, or service commands | Handled through install, renew, and reload hooks | Usually explicit scripts or deployment commands |
| Renewal scheduling | Often supplied by the package or a service, but verify locally | Installer commonly creates a scheduled renewal mechanism | Usually configured by the operator through cron, a timer, CI, or a scheduler |
| Key and certificate storage | Managed configuration directories; inspect the active lineage and permissions | Client-specific home and certificate directories | Directories and filenames selected through command options or automation |
| Container use | Possible, but persistence and web-server access require careful design | Possible, with persistent configuration and scheduled execution | Natural fit for image-based or pipeline-driven workflows |
| Migration difficulty | Low when moving between standard web-server integrations; moderate when changing storage or hooks | Moderate because commands, paths, and renewal jobs differ | Moderate because deployment and scheduling are usually explicit |
For a new conventional VPS, start with the client best supported by your distribution and web server. For a wildcard certificate, first confirm that your DNS provider has a safe API integration; the challenge method matters more than the client’s name. For containers or custom deployment pipelines, prioritize predictable file outputs, secret handling, and an easy-to-test reload hook.
What to track
Validation method and DNS access
Record whether each certificate uses HTTP-01 or DNS-01. HTTP-01 generally requires the client to serve a validation file at the requested hostname. DNS-01 requires temporary TXT records and is commonly used when a wildcard certificate is needed or the web server is not directly reachable. Keep DNS API credentials limited to the zone and permissions required for validation. Never place them in a public repository, image layer, or world-readable configuration file.
Renewal job and its owner
Identify exactly what runs renewal: a systemd timer, cron entry, container scheduler, CI pipeline, hosting panel, or another service. Check whether the job runs as root or as a dedicated account, and whether it can read the private key and contact the web server. Multiple ACME clients attempting to manage the same certificate can create confusing failures, so document the single source of truth for every hostname.
Certificate paths, permissions, and deployment hooks
Track the paths used by the client and the paths consumed by Nginx, Apache, a reverse proxy, a load balancer, or an application. A successful renewal is not enough if the service continues using the previous certificate. The deployment step should copy or link the renewed files as appropriate, apply restrictive permissions, and reload the service only after the new files pass a configuration test.
Logs and test results
Keep the command output, scheduler logs, web-server reload result, and an external HTTPS check where possible. A useful renewal test exercises the whole chain: account access, challenge validation, certificate installation, service reload, and the hostname presented to a client. Use a staging endpoint while building or repairing automation so repeated tests do not unnecessarily request production certificates. See our guide to staging and rate limits for a safer testing workflow.
Client and environment changes
Maintain a small inventory containing the client name, installation method, operating system, web server, DNS provider, challenge type, certificate names, renewal schedule, configuration directory, and last successful test. Review it after package upgrades, operating-system migrations, DNS changes, domain transfers, or a move from a VPS to a container platform.
Cadence and checkpoints
A monthly or quarterly review is usually sufficient for stable infrastructure, with an additional review before any planned migration. Do not wait for expiry warnings. At each checkpoint:
- Run the client’s dry-run, renewal test, or equivalent supported test.
- Confirm that the scheduled job still exists and has run recently.
- Inspect the certificate names, expiration window, and issuer expected by your environment.
- Verify that the private key and certificate files have appropriate ownership and permissions.
- Test the web-server configuration before reloading it.
- Confirm that the application, proxy, or load balancer is presenting the renewed certificate.
- Check that DNS API credentials, tokens, and environment variables remain available without being exposed.
- Review logs for repeated failures rather than treating a single successful run as proof of reliability.
When changing clients, first map the existing workflow. Locate the current certificate, account data, renewal job, hooks, web-server references, DNS credentials, and monitoring. Then reproduce the process in a non-production hostname or staging environment. Do not remove the old automation until the replacement has issued a certificate, installed it, reloaded the service, and passed an HTTPS check.
How to interpret changes
A change in client version is not automatically a reason to migrate. Ask whether the update changes command syntax, plugin availability, default paths, account handling, challenge behavior, or renewal scheduling. Read the client and operating-system documentation before applying a major upgrade, and capture the current configuration so you can roll back safely.
A failed HTTP-01 validation usually points to DNS resolving somewhere unexpected, port 80 being blocked, a redirect or proxy interfering with the challenge path, or another process owning the validation location. A failed DNS-01 validation calls for checking the authoritative nameservers, TXT record visibility, propagation time, zone permissions, and the exact record name produced by the client. If you use DNSSEC, include delegation and validation checks in the investigation; the DNS-01 and DNSSEC guide provides a useful checklist.
A renewal that succeeds but leaves users seeing the old certificate is a deployment problem, not necessarily an issuance problem. Inspect the post-renewal hook, certificate symlink or copy operation, service reload command, and any intermediate proxy or load balancer. Likewise, an installation that works manually but fails on schedule often indicates a different user, PATH, working directory, secret environment, or permission set.
Choose migration when the current client no longer fits the environment: for example, when DNS automation is unreliable, the deployment target has changed, the package is unavailable, or the existing hooks cannot be tested and monitored. Keep the decision based on operational evidence rather than feature lists alone.
When to revisit
Revisit this comparison at least quarterly and whenever a client, operating system, web server, DNS provider, or deployment platform undergoes a major change. Also review it before adding wildcard names, moving authoritative DNS, replacing a VPS, introducing Kubernetes, changing certificate storage, or handing renewal to a hosting panel. Supported plugins, installation commands, configuration paths, and default scheduling behavior can change, so verify them in the current official documentation before copying a command into production.
Use this migration checklist:
- List every hostname, certificate, challenge type, and current certificate path.
- Identify the active renewal scheduler and disable duplicate automation only after the replacement is ready.
- Back up configuration and record file ownership, permissions, hooks, and service reload commands.
- Confirm the new client supports the required DNS provider or web-root layout.
- Test with a staging endpoint or isolated hostname.
- Issue a production certificate during a controlled maintenance window if practical.
- Verify the certificate from outside the server and confirm all proxies present it.
- Monitor the next scheduled renewal and remove obsolete credentials and jobs.
For the surrounding server work, use the secure HTTPS setup checklist and the certificate lifecycle playbook. The best ACME client is the one your team can update, test, monitor, and recover without guesswork.