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.
# Force SSL Certificate
RewriteEngine on
RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]


Thanks for visiting,