I have some websites which are under developing and the most important factor that I care is the speed of them. Speed is not the most important factor for SEO but for me it definitely is. Why? Because when I search for an information through Google and go to a website, it takes me a very long time to load the whole content. I do not have much patience so I give up, thus that site lose a visitor. That’s why I want that every visitor who comes to my website always get satisfied, be ready for reading the content in a blink of an eye.
Let’s see what is my results so far (check with multiple top website’s speed checker)
Google PageSpeed Insight
As you can see that my blog has a very high score (pingdom is nearly 100 score) which is really good. It took only a half of second to fully load the whole website.
So what I’ve done to get this result
Firstly, I check my website’s speed with multiples checker tool as soon as I finished installing it. Then with all the suggestions of those tools, I tried to search for how to fix all issues and I will summarize below:
Install WordPress for your website
Of course WordPress is my first and only choice when I build a website. Everyone does. So no need to talk about this.
Install fresh and ultra light theme/template for your website
Before I thought that my website need to be very beautiful, colorful, has a lot of features so visitor will love. But now, not anymore. I need my website loading as fast as it can. So I choose a super light theme. For me simple is the best. This blog I use Dazzling theme from Colorlib.
Install some plugins which help my site load faster
When I use some tools to check my website’s speed like Pingdom, Gtmextrix…., they scan my whole website and find so many issues. Then they suggest me how to fix those issues to improve my speed. Luckily there are some WordPress’s plugins which can help me to solve those issues. They are:
This plugin help me to optimize all of the images in my website. It’s free, fast and helpful. My website’s speed is increased after using this plugin.
Query Strings Remover
Speed Booster Pack
WP Super Cache
This plugins is popular and famous. It is a very fast caching plugin for WordPress.
You may not have to install a lot of plugins which may cause your site heavier. But if you don’t use plugins you have to edit some codes. With a non-expert like me, I choose plugins instead of changing code lol.
Configuration my hosting cpanel a little bit
Optimize PHP 7.1
Hosting providers always set PHP 5.6 as default, because this version has appeared a long time ago and more compatible with WordPress more than PHP 7.0 and PHP 7.1.
But if you use WordPress, Joomla or Magento you should choose PHP 7.1 instead of PHP 5.6. Because these open sources are updated regularly to 100% compatible with newest version of PHP.
Accroding to some research, PHP 7.1 has performance 3 times compared to PHP 5.6. An additional thing is PHP 5.6 is now stopped developing. See more PHP Supported Versions.
So now you should select PHP 7.1 for your website. All hosting providers allow you to do it via cpanel. I use Siteground hosting so I can change it here like this image below
Just go to PHP Version Manger, choose your domain and change version to PHP 7.1. That’s all.
Add some small code to .htaccess file
This most common thing I face to when those tools check my website is that Leverage Browser Caching. My score is always low. So how to fix it? It’s very simple. Just place this code below at the top of your .htacces file
EXPIRES CACHING ##
ExpiresByType image/jpg “access 1 year”
ExpiresByType image/jpeg “access 1 year”
ExpiresByType image/gif “access 1 year”
ExpiresByType image/png “access 1 year”
ExpiresByType text/css “access 1 month”
ExpiresByType text/html “access 1 month”
ExpiresByType application/pdf “access 1 month”
ExpiresByType application/x-shockwave-flash “access 1 month”
ExpiresByType image/x-icon “access 1 year”
ExpiresDefault “access 1 month”
## EXPIRES CACHING ##
Save the .htaccess file and then refresh your webpage. Then go to speed checker and recheck to see does it affect your website. Just simple as that. If you want to know more, visit Gtmetrix recommendation here.
It took me only 20 – 30 minutes to done all these things. So I recommend you to do this asap after installing your website.