Technology

Install free SSL from Lets Encrypt on Namecheap shared hosting

free ssl, let's encrypt, shared hosting

Google has made SSL a requirement for all websites, which makes it a great time to have SSL on all the websites. Here we will see how we can install free SSL from Let’s Encrypt on Namecheap shared hosting.

Generating the free SSL certificate

Go to SSL for free website.

It first prompts to enter the website url. Once we fill your domain name, it should add both the url’s with the www and non-www domain.

First it is required to verify the ownership of the domain which can be done in 3 ways:
1. Automatic FTP verification
2. Manual verification which will require uploading a couple of files to the web host
3. Manual verification via DNS which will require us to add a TXT record to the DNS server.

I went via the second method which included the uploading of a couple of files to the hosting. To do this, select “Manual Verification”. This should show the steps required to do the same.

Then click on “Manually Verify Domain”
This will open up to show 2 files which need to be downloaded and the steps to upload them to the server and verify.
The files need to be uploaded to the base folder of the website. In my case, the folder was public_html.

Once you are inside the base folder, i.e.: public_html, create a folder name .well-known and inside it another folder named acme-challenge. The 2 files that we downloaded earlier needs to be uploaded here.

So now the files could be discover-able at the following urls
domainname.com/.well-known/acme-challenge/file1
domainname.com/.well-known/acme-challenge/file2

Click on “I have my Own CSR” (if you have one) checkbox and then “Download SSL Certificate”
You should see something like:

ssl certificate files

Installing the Certificate

Now we can head-over to cPanel and go to SSL/TLS.
There go to SSL Certificates, and copy paste the Certificate code received in the SSL for free website. Then click on save.

Again go back to SSL/TLS and go to Manage SSL Hosts and install the newly fetched SSL certificate.

Now you can access your website over SSL.

Conclusion

SSL Certificates generated by Let’s Encrypt are valid for only 90 days. So make sure to re-generate the certificate every 90 days to avoid expiration.

A complete guide from SitePoint can be found here

You can also read on how to install install free SSL from Let’s Encrypt on Dokku here.

Leave a Reply

Your email address will not be published. Required fields are marked *