How to Get a Let’s Encrypt Certificate for an IP Address: A Detailed Technical Guide
This is a tricky subject because Let’s Encrypt is designed to issue certificates only for domain names (FQDNs) under the control of the requester. However, in certain scenarios—such as internal tools, testing servers, or services bound to public IPs—you may want SSL encryption without buying a custom domain.
In this article, we’ll walk through what’s possible, what isn’t, and the technical workarounds for using Let’s Encrypt certificates with IP addresses.
Before diving into the how-to, let’s understand the limitations. SSL/TLS certificates rely on a Subject Alternative Name (SAN) field to validate identities. Typically, these SANs are domain names like example.com or api.example.org.
The challenge with IP addresses is:
203.0.113.10. Their ACME protocol requires proof of control over a domain.That said, there are workarounds and alternatives you can use to secure services running on IPs.
The most reliable solution is to map your server’s IP address to a free or low-cost domain and then use Let’s Encrypt as usual.
You can register a domain from providers like:
.tk, .ml, .ga)A myserver.example.com 203.0.113.10AAAA myserver.example.com 2001:db8::1On a Linux server (e.g., Ubuntu/Debian):
sudo apt update
sudo apt install certbot python3-certbot-nginx
For Apache:
sudo apt install certbot python3-certbot-apache
Run Certbot with your domain:
sudo certbot --nginx -d myserver.example.com
This configures SSL automatically. For Apache:
sudo certbot --apache -d myserver.example.com
Certificates from Let’s Encrypt are valid for 90 days, but Certbot can auto-renew. Test renewal with:
sudo certbot renew --dry-run
If you absolutely must use the raw IP address in the browser (e.g., https://203.0.113.10), you’ll need to fall back to a self-signed certificate. While not trusted by default, you can manually add it to your system or browser trust store.
openssl req -x509 -nodes -days 365 -newkey rsa:2048
-keyout ip.key -out ip.crt
-subj "/CN=203.0.113.10"
This creates:
ip.key → Private keyip.crt → Self-signed certificateserver {
listen 443 ssl;
server_name 203.0.113.10;
ssl_certificate /etc/nginx/ssl/ip.crt;
ssl_certificate_key /etc/nginx/ssl/ip.key;
location / {
root /var/www/html;
}
}
Reload Nginx:
sudo nginx -s reload
Another trick is to use a reverse proxy such as Nginx or Traefik that terminates TLS for a domain and forwards traffic to your IP service.
For example:
This way, clients access the secure domain, but your internal service can still run on IP.
Traefik can automatically handle Let’s Encrypt with DNS-01 or HTTP-01 challenges. In traefik.toml:
[entryPoints]
[entryPoints.websecure]
address = ":443"
[certificatesResolvers.myresolver.acme]
email = "admin@example.com"
storage = "acme.json"
[certificatesResolvers.myresolver.acme.httpChallenge]
entryPoint = "web"
Then map your service under the secured domain.
While Let’s Encrypt doesn’t support IP SANs, a few commercial certificate authorities do issue them, typically for enterprise use cases. For example:
These often come at a cost and may require proof of IP ownership (e.g., via WHOIS).
301 redirects in Nginx or Apache./var/log/letsencrypt/letsencrypt.log).Getting a Let’s Encrypt certificate for a bare IP address is not possible due to CA restrictions. The best approach is to register a domain, point it to your server’s IP, and obtain a free certificate via Certbot.
For scenarios where you can’t use a domain, you’ll need to either:
For most use cases, the domain-based method is the simplest, most secure, and future-proof approach. With proper setup, you’ll have a fully automated, free, and trusted SSL/TLS solution securing your server—whether it’s a website, an API, or an internal service.
The post How to Get a Let’s Encrypt Certificate for an IP Address: A Detailed Technical Guide appeared first on Cyber Security News.
Today: The appraisal of SARL.com / LimonYSalVentura.com sold for $8,186 / Evaluating EmailField.com and More……
Barbara Simmons serves as executive director of The Peace Center, an educational peace and justice…
Over the last 48 hours, something different has been unfolding on X & LinkedIn –…
Mario Day, or "MAR10 Day," is back again this year, and Nintendo is kicking off…
Today's links The web is bearable with RSS: And don't forget "Reader Mode." Hey look…
Artificial Intelligence Watershed Moment for AI–Human Collaboration in MathBenjamin Skuse | IEEE Spectrum “The 8-dimensional…
This website uses cookies.