Make your website secure with Let’s Encrypt (Certbot) free SSL.

Make your website secure with Let’s Encrypt (Certbot) free SSL. post thumbnail image

It is important to use SSL to make your website encrypted. In this method, I will show you how to install SSL in Ubuntu 16.04.

  1. First, you need to install certbot tool by the below command

root@Linoide:~# apt update root@Linoide:~# apt install letsencrypt

2. Now Generate wildcard SSL using certbot tool.

root@Linoide:~# certbot certonly --manual --preferred-challenges=dns --email --server --agree-tos -d -d '*'

Note: ’email’ , ‘-d (domain name)’ with your own email and domain name.

You need to type ‘Y’ two times while deploying this command and then finally the out looks like this

Please deploy a DNS TXT record under the name with the following value:
Before continuing, verify the record is deployed. 

3. Now, create a TXT name in Godaddy(or your domain provider) as below. After record added, wait for few minutes and then click ENTER to continue  deploy in your server. 

Note: Domain provider will take several minutes of time to update your record.

Example Output:

Congratulations! Your certificate and chain have been saved at:
Your key file has been saved at:
Your cert will expire on 2022-10-17. To obtain a new or tweaked
version of this certificate in the future, simply run certbot
again. To non-interactively renew all of your certificates, run
"certbot renew"
Your account credentials have been saved in your Certbot
configuration directory at /etc/letsencrypt. You should make a
secure backup of this folder now. This configuration directory will
also contain certificates and private keys obtained by Certbot so
making regular backups of this folder is ideal.
If you like Certbot, please consider supporting our work by:
Donating to ISRG / Let's Encrypt:
Donating to EFF:

4. You can check your all certbot certificates by using this command

# certbot certificates

Example Output

root@Linoide:~# certbot certificates
Saving debug log to /var/log/letsencrypt/letsencrypt.log

Found the following certs:
Certificate Name:
Domains: *
Expiry Date: 2021-01-15 14:11:10+00:00 (VALID: 89 days)
Certificate Path: /etc/letsencrypt/live/
Private Key Path: /etc/letsencrypt/live/

Congratulations! You have installed free SSL certificate on your server.

But Wait……

Its for only 90 days. What about after that? Do you need to create another certificates or follow all these process again and again?


Just create a cronjob to renew certbot certificates automatically.

5. Run this command to edit cronjob

root@Linoide:~# crontab -e

and now add below line to your cronjobs and save the file

0 1 * * * /usr/bin/certbot renew >> /var/log/letsencrypt/renew.log

That’s it!

SSL Certs are created now you need to enable them into your webpage. Let’s enable SSL

Related Post