EN · $ USD
Domains, DNS and SSL

How to Install a Free SSL Certificate (AutoSSL and Let's Encrypt)

7 min read Updated: Sunucu Atlas technical team

In short

There are two common ways to install a free SSL certificate: on cPanel hosting, AutoSSL issues and renews the certificate automatically once the domain points to the server; on a VDS, you get a Let's Encrypt certificate with Certbot, install it on Nginx or Apache, and let a systemd timer renew it automatically. With both methods, the domain's DNS must point to the server and port 80 must be reachable.

In this guide
  1. A Quick Primer on SSL Certificates and Free Certificates
  2. Method 1: Automatic Setup With cPanel AutoSSL
  3. Method 2: Installing Let's Encrypt With Certbot on a VDS
  4. Checking Automatic Renewal
  5. AutoSSL or Certbot?
  6. Next Step: Choose Infrastructure With SSL Included

Installing a free SSL certificate now takes just a few minutes. On hosting that uses cPanel, AutoSSL issues the certificate on its own as soon as your domain points to the server and renews it before it expires. On a VDS you manage yourself, you get a Let's Encrypt certificate with the Certbot tool, install it on your web server and leave renewal to a timer. In this guide we cover both methods, their prerequisites and, most importantly, how to verify that automatic renewal actually works.

A Quick Primer on SSL Certificates and Free Certificates

An SSL/TLS certificate encrypts traffic between the browser and the server and verifies that the site really belongs to that domain. If there's no certificate or it has expired, browsers show a "Your connection is not private" warning; for every cause of this error, see our SSL error troubleshooting guide.

Free certificates are domain validated (DV) certificates: they only prove the domain is under your control. Their encryption strength is the same as paid DV certificates. The difference is that they're short-lived; Let's Encrypt certificates are valid for 90 days, and certificate lifetimes are gradually getting shorter across the industry. That's why automatic renewal is a must instead of renewing by hand.

How is the domain validated?

  • HTTP validation (HTTP-01): The certificate authority reads a temporary file under your site's /.well-known/ path over port 80. This is the most common method.
  • DNS validation (DNS-01): A temporary TXT record is added to the domain. It's required for wildcard certificates (*.firmaniz.com).

Method 1: Automatic Setup With cPanel AutoSSL

AutoSSL is the cPanel feature that issues and renews free DV certificates for every domain and subdomain on the account. On shared hosting you usually don't need to do anything; but if the certificate hasn't arrived, follow these steps:

  1. Check DNS. The domain's A record must point to the hosting server's IP. If you just changed nameservers, wait for propagation; for connection steps, see the guide on connecting a domain to hosting.
  2. In cPanel, open the SSL/TLS Status screen in the Security section.
  3. Check the status of the domain and subdomains like www and mail in the list. If a lock icon isn't green, read the note next to that row.
  4. Click Run AutoSSL. The process can take a few minutes.
  5. When it's done, the certificate is installed automatically; open the site with https:// and check the lock icon.

When you add an addon domain or subdomain to your account, AutoSSL issues certificates for those names on its next run. If you want a newly added site to load over HTTPS without waiting, just click Run AutoSSL again once DNS pointing is complete. For domains where you've installed a paid certificate you bought yourself, AutoSSL does not overwrite the valid certificate.

Why won't AutoSSL issue a certificate?

  • DNS points to another server: If one of the subdomains (for example www) goes to the old host or a proxy, that name can't be validated.
  • .htaccess is blocking the validation file: Rules that redirect every request elsewhere or restrict access also affect the /.well-known/ path. If needed, add this exception before your rules:
RewriteEngine On
RewriteRule ^\.well-known/ - [L]
  • A CAA record is restricting it: If the domain has a CAA record, it must allow the certificate authority being used.
  • Unused subdomains: Subdomains with no matching DNS entry can't be validated; in that case only that name is excluded, and the main domain still gets a certificate.

After the certificate is installed, don't forget to redirect visitors to HTTPS. The Force HTTPS Redirect toggle on the Domains screen in cPanel does this in one click; writing a 301 redirect in .htaccess also works.

Mixed content warning

If the certificate is installed but the browser still doesn't show the lock icon, the problem is usually the page, not the certificate. If a page loaded over HTTPS still calls images, scripts or stylesheets from http:// addresses, the browser flags this as "mixed content" and may not load some files at all. The fix is to update the site address in your settings to https:// and change hard-coded http:// links in the database or theme files. In WordPress, first update the two address fields under Settings > General, then use a search-and-replace tool for old links. The Console tab in your browser's developer tools lists the problem files directly.

Method 2: Installing Let's Encrypt With Certbot on a VDS

Let's assume you're running Nginx on an Ubuntu VDS without a control panel. Certbot is the ACME client recommended by Let's Encrypt, and it can also edit your Nginx configuration automatically. For the current installation method, you can also check the official Certbot website.

Prerequisites

  • The domain's A record (and AAAA, if any) must point to the VDS IP address.
  • Nginx must have a site configuration for the domain that includes the line server_name firmaniz.com www.firmaniz.com;.
  • Ports 80 and 443 must be open in the firewall.

Step-by-step installation

  1. Allow HTTP and HTTPS in the firewall:
    sudo ufw allow 'Nginx Full'
    sudo ufw status
  2. Install Certbot with snap (the recommended method on Ubuntu):
    sudo snap install --classic certbot
    sudo ln -s /snap/bin/certbot /usr/bin/certbot
  3. Get the certificate and install it on Nginx:
    sudo certbot --nginx -d firmaniz.com -d www.firmaniz.com
    Certbot asks for an email address and for you to accept the terms of service; it then obtains the certificate, adds the ssl_certificate lines to your Nginx configuration and sets up the HTTP-to-HTTPS redirect.
  4. Test the configuration and reload Nginx:
    sudo nginx -t
    sudo systemctl reload nginx

If you use Apache, use the --apache parameter instead of --nginx in the same steps and open the 'Apache Full' profile in the firewall. The certificate files live under /etc/letsencrypt/live/firmaniz.com/ as fullchain.pem and privkey.pem. If you're setting up the server from scratch, first follow the guide on installing Nginx, PHP and MySQL (LEMP) on Ubuntu.

Adding a new domain to the certificate

When you launch a new subdomain on the same server (for example api.firmaniz.com), you have two options. For a separate certificate, run Certbot with only that name. To expand the existing certificate, list all the names again and add the --expand parameter:

sudo certbot --nginx --expand -d firmaniz.com -d www.firmaniz.com -d api.firmaniz.com

If you need a wildcard certificate, DNS validation is required instead of HTTP validation. The command sudo certbot certonly --manual --preferred-challenges dns -d "*.firmaniz.com" asks you to add a TXT record; however, this manual method doesn't renew automatically. For long-term use, choose a Certbot plugin that works with your DNS provider's API.

Checking Automatic Renewal

Most SSL problems show up not at the initial install but months later, when renewal fails silently. Since Let's Encrypt no longer sends expiration reminder emails, it's up to you to check.

Certbot on a VDS

# Is the renewal timer running?
systemctl list-timers | grep certbot

# Test renewal without touching the real certificate
sudo certbot renew --dry-run

# Installed certificates and their expiry dates
sudo certbot certificates

If --dry-run completes without errors, renewal will work fine. Certbot renews certificates nearing expiry on its own; if you want to make sure Nginx loads the new certificate, you can add a deploy hook:

sudo sh -c 'printf "#!/bin/sh\nsystemctl reload nginx\n" > /etc/letsencrypt/renewal-hooks/deploy/reload-nginx.sh'
sudo chmod +x /etc/letsencrypt/renewal-hooks/deploy/reload-nginx.sh

cPanel AutoSSL

AutoSSL handles renewal itself at regular intervals at the server level. What you need to check is that every name shows green on the SSL/TLS Status screen and that DNS keeps pointing to the server. If you've moved DNS elsewhere, renewal will fail too.

External check for both environments

To see the certificate's expiry date from the outside, run this in any Linux or macOS terminal:

echo | openssl s_client -connect firmaniz.com:443 -servername firmaniz.com 2>/dev/null | openssl x509 -noout -dates

AutoSSL or Certbot?

CriterioncPanel AutoSSLCertbot on a VDS
InstallationAutomatic, one button in the panelA few steps on the command line
RenewalManaged by the panelsystemd timer; under your control
Wildcard certificateDepends on server configurationPossible with DNS validation
Best forWebsites, blogs, business sitesCustom applications, APIs, Docker and Node.js projects

Next Step: Choose Infrastructure With SSL Included

If you don't want to deal with certificates, every Sunucu Atlas web hosting plan includes a free SSL certificate; when you connect your domain, the certificate is installed and renewed automatically. If you want to manage your own Nginx configuration, application server or Docker projects, the Ryzen Premium VDS plans with root access and KVM virtualization give you the full control you need to install Certbot; for a single site or a small API, SA-R9-2 is a comfortable starting point. If you get stuck during setup, open a support ticket for help in Turkish.

Frequently asked questions

Is there a security difference between free and paid SSL?

There's no difference in encryption strength. Paid certificates offer organization validation (OV/EV), warranties and longer support options; for most websites, a free DV certificate is enough.

How long is a Let's Encrypt certificate valid?

Let's Encrypt certificates are valid for 90 days, and lifetimes are gradually getting shorter across the industry. That's why automatic renewal with Certbot or AutoSSL is necessary.

Why won't AutoSSL issue a certificate for www?

Usually the DNS record for the www subdomain is missing or points to a different server. Add a CNAME for www pointing to the root domain, or an A record to the same IP, then run AutoSSL again.

How do I know Certbot renewal is working?

If the sudo certbot renew --dry-run command completes without errors, renewal works. You can also confirm the timer is active with systemctl list-timers.

Can I get a wildcard SSL certificate for free?

Yes, Let's Encrypt issues wildcard certificates; however, validation can only be done with the DNS-01 method, by adding a TXT record to the domain.

For this guide

Recommended plans

Sunucu Atlas web hosting plans install and renew free SSL automatically, while Ryzen Premium VDS gives you root access and full control over Certbot and your own web server configuration.

SA-CP-1

cPanel
Recommended

20 GB NVMe disk

$0.39/mo

+VAT

  • Memory1 GB
  • LocationIstanbul
  • 1 Hosted Domains
  • 50 GB Traffic
  • 5 Email Account Limit
  • 2 Databases

SA-CP-2

cPanel

40 GB NVMe disk

$0.69/mo

+VAT

  • Processor2 cores
  • Memory2 GB
  • LocationIstanbul
  • 1 Hosted Domains
  • 100 GB Traffic
  • 10 Email Account Limit
  • 5 Databases

SA-CP-3

cPanel

60 GB NVMe disk

$0.98/mo

+VAT

  • Processor3 cores
  • Memory3 GB
  • LocationIstanbul
  • 1 Hosted Domains
  • 200 GB Traffic
  • 25 Email Account Limit
  • 10 Databases

Web Hosting — all plans Ryzen Premium VDS — tüm paketler

Need help with setup?

Send questions about your service in a support ticket, and our technical team will walk you through it step by step.