Easy to Install Let’s Encrypt SSL Certificates using Python Certbot

In this tutorial, we will show you how to install Let's Encrypt SSL certificates with Certbot. Let`s Encrypt is a completely free and automated open source Certificate Authority (CA) that offers free Domain Validated (DV) certificates for your websites. SSL certificates are used to establish a secure and encrypted connection between a web server and a user's web browser.  SSL certificates  issued by Let`s Encrypt are valid for 90 days and are now classified as trusted by most web browsers. 

Let's Encrypt has an automatic installer called Certbot. With Certbot, you can  easily add a certificate to your site in  minutes. Certbot can be used on  Nginx and Apache servers and  is compatible with various Linux distributions such as Ubuntu, Debian or CentOS. In this tutorial, we will show you how to install Let's Encrypt SSL certificate on Ubuntu 16.04 using Apache web server.

Please follow instruction if you don't want get misunderstanding:

1. Install Certbot

To install Certbot, simply run the following commands:

apt-get install software-properties-common python-software-properties

add-apt-repository ppa:certbot/certbot

apt-get update

apt-get install python-certbot-apache

2. Install Let’s Encrypt SSL Certificate

To install a Let`s Encrypt SSL certificate on your domain, run the following command (make sure to replace `yourdomain.com` with your actual domain name):

certbot --apache -d yourdomain.com

You will then be asked to enter an email address and  read and accept the terms of use. This is how the output should look  during  installation.

3. Redirect HTTP to HTTPS

Additionally, you can also make a choice if you would like to redirect all the HTTP traffic to HTTPS

Please choose whether or not to redirect HTTP traffic to HTTPS, removing HTTP access.


1: No redirect - Make no further changes to the webserver configuration.

2: Redirect - Make all requests redirect to secure HTTPS access. Choose this for

new sites, or if you're confident your site works on HTTPS. You can undo this

change by editing your web server's configuration.

 4. Automatic renewal

You can also create a cron job in order to set up an automatic SSL renewal.

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

 service cron restart

That’s it. You can now open https://yourdomain.com in your browser and verify whether the Let’s Encrypt SSL certificate has been installed properly.

If you liked this post, on how to install Let’s Encrypt SSL Certificate using Certbot, please share it with your friends. Thanks

Posting Komentar

Lebih baru Lebih lama