Since I moved our blog from HTTP protocol to HTTPS, there are plenty of questions I have received from various users to share the steps to secure your site with HTTPS. After receiving so many requests, I have decided to build a simple, complete tutorial to move WordPress site from HTTP to HTTPS.
First, let us see the advantages of HTTPS over HTTP.
- Trust – Your data is secure on our site
- SEO –Â Google uses HTTPS as a ranking single for SEO
- Speed – With HTTPS/2 support from host, site loading speed has increased
Well, there many be many more advantages, but above three are key advantages, which has made me to switch to HTTPS.
Now let us see quickly various steps about how to move from HTTP to HTTPS.
Note: During this process, you may be logged out from your WordPress Admin, do not worry, just log back in again.Â
Note: If you are using a CDN, you may want to reach out to your CDN partner to know additional steps required to change from HTTP to HTTPS.
Step 0: Backup Everything
I can’t stress on this subject. Please backup everything before you make a single change in your system. Though, this tutorial is from my experience, you must do be capable to restore your site before you proceed with the following steps.
Step 1: SSL Certificate
I have requested my host to install FREE Let’s Encrypt certificate for my domain. It was installed very quickly in five minutes of time and enabled HTTPS protocol for my website.
Trust me, this is the only step where you have to depend on your host doing anything. You can buy expensive SSL certificates, but FREE Let’s Encrypt certificate is indeed a great enough.
Step 2: Change Links
Change all the links in blog for your domain from HTTP to HTTPS. I have used a plugin: Better Search Replace to do so. However, you can do it by either directly updating the database or going through every single link manually. This is a very important task and I suggest you depend on trust solutions. If you miss any link to update, you may eventually see warning related to mixed content.
Step 3: Change WordPress Address and Site Address
I hardly see people talking about this particular setting online. It is very important that we change our WordPress Address and Site Address in WordPress’s General Settings.
Step 4: Change .htaccess and add 301 Redirect
This is a very critical step and that is why it is last. Find .htaccess file inside the root of your domain and add following redirect.
RewriteEngine On RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
Above redirect will force HTTPS with 301 redirect which is good for your SEO.
Done!
You are done. Yeah! It is indeed that easy to change your site from HTTP to HTTPS. Once you do this, there are a few follow up steps you must follow to make sure your website remains searchable and available. It took me around total of 15 minutes of time to complete this entire task flawlessly.
Follow Up Steps
- Add your HTTPSÂ site to Google Webmaster Tools
- Change the reference in Google Analytics Profile
- Change any hard-coded links in robot.txt
Let Me Help You
If you need further help. Do let me know and I will be happy to help. You can either leave a comment here or reach out to me via hire me.
Reference: Pinal Dave (http://blog.SQLAuthority.com)
2 Comments. Leave new
Thank you Pinal, I will also buy https for my blog (dbrnd.com). If possible, would you please share name of host provider and yearly cost of your https. I hosted my wordpress.org blog in bluehost.com