Installing Let's Encrypt with Drupal

letsEncryptLet's Encrypt allows you to secure traffic to your website.  This article describes how to encrypt a Drupal website.


Create an SSL Certificate

You'll need to create an SSL Certificate for this domain.  Here's how to use Let's Encrypt with Siteground hosting.

 

Configuring Drupal

We will start by editing the .htaccess file.

  1. Browse to the root directory for the website.
  2. Open the .htaccess file for editing.
  3. Add the following content to the top of the file.
# The following is needed for SSL Certificate
RewriteCond %{HTTPS} off [OR] RewriteCond %{HTTP_HOST} ^www\.example\.com* RewriteRule ^(.*)$ https://example.com/$1 [L,R=301]

 

Thanks for visiting.