You have enabled SSL certificate for your OpenCart site, but it's disappearing from some pages? Apache Server This tutorial is valid if your OpenCart store runs on an Apache server. You can take the following steps to secure every page of your online store and ensure that online shoppers can browse your site with confidence....

Step 1

Use your favorite FTP client or file manager in cPanel and edit your .htaccessnfile.

OpenCart .htaccess

Step 2

Copy and Paste these 3 lines of code in the .htaccess file:

RewriteEngine On

RewriteCond %{HTTPS} off

RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

Save & close!

Step 3

Edit your config.php file in the OpenCart root (underneath the .htaccess file in the above screenshot).

OpenCart config

Under the // HTTPS line, change the protocol from http to https.

Save & close!

Step 4

Repeat the same for the config.php file in your admin folder.

OpenCart Admin Folder

Open the config.php here:

Config OpenCart

Again, underneath the // HTTPS line change both http protocols to https.


Save & close!


Now go back to your OpenCart website and go through the pages.

OpenCart SSL

You will see the SSL certificate active all around your website keeping each page secure.

Customers will now feel they’re browsing and shopping securely from your OpenCart store.

Secure OpenCart Checkout SSL


Share this tutorial if it helped you and subscribe to our blog for weekly updates with more helpful guides like this one.