Whether you are a developer or an ordinary internet user, almost all of us loves faster websites. This post is focused on how to increase page speed using Htaccess (WordPress). There are lots of ways…
A while back, I did a lot of study and research, particularly for WordPress blogs or websites, to improve my blog page load speed. Internet is full with lots of tutorials, tips and tricks to increase webpage speed. And one can easily get confused which method should be used or which should not be used. Trust me, I have tried almost all the methods and finally I come up with an easy solution to improve page speed.
Before start discussing about Minifying or Minification of your web page, first of all we need to know its importance.
Why Minifying is so Important?
What is Minifying or Minification?
Minifying process particularly removes any unwanted code from your website like;
- Unused spaces that is written in your CSS,
- Unnecessary line-breaks in your HTML or
Therefore, Minification is very crucial and helpful to increase your page load speed.
First you should mark a Baseline of your Website
First you need to know about the current status of your website. Get the baseline data of your website from Webpage analysis tools. There are many Webpage analysis tools available online for free. I would recommend you to get your PageSpeed Score from Google PageSpeed Insights, GTmetrix and Pingdom.
Take a look on your PageSpeed Scores and note down the Page Size, Load time and Number of Requests, I prefer Pingdom for these results. All you need to do is reduce your Page Size and Number of Requests because this is directly related to your Page Load Time.
Low Page Size + Less Number of Requests = Less Page Load Time.
Why I am suggesting a plugin instead of using a code in functions.php? Well, it is really not that much easy to implement code for Minification. This is the case where use of plugin is highly recommended. It will let you update your theme on regular basis, any theme update will not hamper your file Minification process. So, let’s start…
#1 – W3 Total Cache
- Install W3 Total Cache plugin and Activate it.
- Go the General Settings Tab and Find Minify settings.
- Check Minify Enable setting as show in figure below and leave other options as default.
- Click on Save all Settings button, Clear all cache. And you are done.
- You want to utilise more power from this plugin, read our detailed W3 Total Cache plugin setup guide for maximum performance.
#2 – Autoptimize
Second plugin on this list is one of my favourite plugin; Autoptimize, I would highly recommend you to use this plugin. This plugin works pretty well, it has very simple user interface, setting options for normal and advance users. Use given below optimized settings (See screenshot below) for Autoptimize plugin.
- Install this plugin and activate it.
- Go to plugin’s setting panel
- Finally click on the Save Changes and Empty Cache button.
#3 – WP Fastest Cache
Next plugin is WP Fastest Cache. I personally use this plugin and also recommend this to Leverage Browser Caching. You must be thinking, why i have included this into this list.? Any Guesses?
If you are obsessed with Google PageSpeed Insights and wanted to achieve 100 out of 100. I must recommend you to use this plugin. You will score 98 out of 100 easily. But what about rest 2 because of Leverage Browser Caching Warning for Google Analytics. Read my another guide on How to Leverage Browser Caching – Google Analytics and Achieve 100/100 score on Google PageSpeed Insights.
#4 – Fast Velocity Minify
- Better WordPress Minify – It used to be a good plugin and most popular for minifcation. I have stop recommending it because it has not been updated from last two years. However, I have tested it with WordPress 4.7.5 and this was working perfectly fine. With more 90K active installs, you can give this a try.
- WP Super Minify – This plugin is quite popular with more >20K active installed. It is based on the Minify PHP Framework.
All the above mention plugins are available on WordPress Repository for free.
Online tools to Minify CSS – You can use these online tool can Minify your CSS files.
You might be interested to read following tutorials –
How to Add Subscribe to Comments in WordPress
CSS Changes not Showing Up in WordPress – Cache Busting CSS
How to Lazy Load Images in WordPress to Speed Up Your Website
Cache Gravatar Images in WordPress for WP Optimization