TutorialsWordPress

Installing SSL certificate in WordPress

Learn how to install an SSL certificate in WordPress, ensuring automatic redirection to HTTPS and encryption of transferred data. Follow the simple steps!

25
Views 6597Updated 2 luniPublished on 28/02/2018by Cătălin Adrian

Introduction

In this tutorial, we will present the necessary steps for implementing an SSL certificate in the WordPress application, using the settings available in the administration side (wp-admin). After completing these steps:

  • Any unsecured access to the site (e.g. https://domain.extension) will be automatically redirected to the secure version (e.g. https://domain.extension).
  • All data transferred between users and the server will be encrypted.

As an example, we will use the subdomain demo.hostico.ro.

Requirements

To go through this process, you need the following:

  • The login details for the administration panel WordPress (wp-admin).
  • An SSL certificate installed on the hosting account for the domain where the WordPress application runs.

Steps

  1. Log in to the WordPress administration panel by accessing domain.extension/wp-admin or the preferred address set.

Administrare WordPress

  1. From the navigation bar, go to Settings and click on General.

Selectare Settings General

  1. In the general settings page, locate the fields WordPress Address (URL) and Site Address (URL). If SSL is not activated, these fields will contain the site's address in an unsecured format (HTTP).
  2. Change the respective addresses from https://demo.hostico.ro to https://demo.hostico.ro.

Modificare link HTTP/HTTPS

  1. Click on Save Changes to save the changes.

From now on, all unsecured accesses to the site will be redirected to the secure variant, and resources (images, CSS files, JS, etc.) will be loaded via the HTTPS protocol.

Redirects via the .htaccess file

If the redirection to HTTPS does not happen automatically, you need to edit the .htaccess file in the root folder of the domain and add the following lines at the end of the file:

RewriteEngine OnRewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

The .htaccess file can be edited using the File Manager in cPanel. If you do not see the .htaccess file, enable the display of hidden files in the File Manager by following this tutorial.

Security errors displayed in the browser

There may be cases where, even after implementing the SSL certificate, the browser displays warning messages (e.g., a yellow padlock in the navigation bar). These are caused by resources that are still loading via HTTP.

  • To identify these resources, open the page source (right click → View Page Source) and search for HTTP links using Ctrl + F.
  • The identified resources must be manually modified to use the HTTPS protocol. They can be found in the PHP code, in the database, or in the settings of some plugins.

Similar Articles

Transfer .ro domainTutorials /Domains

This tutorial presents the steps necessary to obtain the authorization key from the ROTLD panel for transferring a .ro domain to a new registrar.

73
by Mark Dohi
Views 8849
Updated 9 months ago
Published on 06/02/2018
Changing the PHP version in cPanel on VPS hosting packages via MultiPHP ManagerTutorials /cPanel

In this article, we will present the necessary steps to change the PHP version in a cPanel account using MultiPHP Manager.

42
by Sebastian Szlivka
Views 1899
Updated 10 months ago
Published on 18/10/2017
Unblocking IP from Hostico serversTutorials /Dev

In this tutorial, the necessary steps will be presented to unblock the IP listed in the firewall on Hostico servers.

31
by Mark Dohi
Views 892
Updated 9 months ago
Published on 05/10/2020
Creating an email account in cPanelTutorials /cPanel

The cPanel allows for the creation of an unlimited number of email accounts associated with hosted domains. This tutorial will explain the necessary steps to create and access an email account.

22
by Cătălin Adrian
Views 3766
Updated 10 months ago
Published on 28/06/2017
SSH settings in WebuzoTutorials /Webuzo

In this tutorial, learn how to block SSH access on the Webuzo server by enabling the connection and configuring the necessary port.

20
by Alexandru Rogojan
Views 522
Updated 2 months ago
Published on 12/06/2018