Understanding Page Speed in WordPress
There are three main legs when it comes to determining a page’s ranking in a Google search result:
Google’s continuous mission is to deliver content that answers a user’s question in the most thorough and authoritative way. It’s a bit overly simplistic, but these two legs are what make effective keyword usage and link building so important for SEO.
But what about that third leg?
There are lots of ingredients that make up a “quality” page, but one of the biggest factors is page speed.
What does “page speed” mean?
Page speed is the amount of time it takes to fully load the content of a web page.
This measurement includes the time it takes for a browser to establish a connection to server, request a page, have the server receive that request and have browser receive, load and render the page.
“Page speed” shouldn’t be confused with the concept of site speed, which is the average page speed for a representative sample of pageviews on a single website.
How do you measure site speed?
Page speed can be measured as “page load time” — the time it takes for the page to fully load and display, or “time to first byte” (TTFB) — the time it takes a browser to receive the first byte of data from a server.
Google has been pretty cryptic when it comes to how they measure and evaluate site speed. This shouldn’t be much of a surprise to anyone.
A few years ago, there were some signs that Google relied on TTFB as a way to measure page speed, but that was debunked by John Mueller.
AFAIK we currently don't use TTFB for anything in search/ranking. It can be a good proxy for user-facing speed, but like other metrics, don't blindly focus on it.
— John ☆.o(≧▽≦)o.☆ (@JohnMu) November 30, 2017
So, for SEO purposes, it’s best to focus on reducing overall page load time instead of obsessing over TTFB.
Why Does Page Speed Matter for WordPress Sites?
As we’ve just established, your WordPress page speed can have a serious impact on Google rankings. It’s also important for your site’s overall user experience.
In fact, 47% of shoppers expect a page to load in 2 seconds or less. They’ll abandon a product page that takes 3 seconds or more to load. And, just critically, 79% of shoppers won’t buy from a website that provides a poor user experience.
Read more important stats about page load time and UX here.
And “poor UX” definitely includes page load time.
How Do You Improve Your WordPress Page Speed?
Based on the Underscores framework, RedWaves is a blazing fast and lightweight WordPress Blog theme yet powerful and very customizable with responsive design, clean code, SEO friendly and Adsense read …
- Responsive Design
- Adsense Ready
- 2 Display Layouts
- Custom Sidebar Positions
There are some basic steps you can take to improve the page speed of pretty much any web page. These best practices include things like:
- Reducing or eliminating redirects
- Minifying code
- Using Gzip or other compression
- Leveraging browser caching
However, since WordPress is a unique platform when it comes to creating and optimizing web sites, we’ve put together 5 steps you can take to make sure your WordPress pages are as fast as possible.
1. Optimize WordPress settings
There are two WordPress settings you can change to help boost your page load time:
- Disabling wp-cron.php
- Disabling autosave
The wp-cron.php is a script that runs every time someone visits your website that asks if they have any tasks to complete. So when your visitors start rolling in, this script can be called dozens, of even hundreds, of times per our.
Luckily, you can change your WordPress settings to run this script manually.
To do this:
- Go to your File Manager editor in your cPanel
- Open your `wp-config.php` file
- Go to around line 37 and add this code:
/** The Database Collate type. Don't change this if in doubt. */ define('DB_COLLATE', ''); **define('DISABLE_WP_CRON', 'true');**
- Click save.
- Go back to your cPanel and go to Advanced Settings> Cron Jobs.
- Change the Common Settings to “Once Per Hour”.
- From the drop down, select “Every Sixth Hour”.
- Add this code to your Command section:
cd /home/**YOURUSERNAME**/public_html; php -q wp-cron.php
- Change the `YOURUSERNAME` to your cPanel username.
- If you use any subdomains on your website, you’ll need to do this for each subdomain.
Disabling WordPress autosave
WordPress will periodically autosave your activity when working on drafts. This is super helpful if you’re the type of person who forgets to save drafts, but can result in hundreds, if not thousands, of rather unnecessary requests.
To disable autosave for your WordPress site, follow these steps:
- Go to your cPanel
- Open the File Manager Code Editor
- Look for `wp-config.php` and paste in this code:
* @package WordPress */ **define('AUTOSAVE_INTERVAL', 86400);** // ** MySQL settings - You can get this info from your web host ** //
This change will tell WordPress to autosave drafts every 86,400 seconds, which is equal to 1 24-hour period.
Be warned: you now must remember to save your drafts manually!
2. Choose a good host
There are a lot of cheap, and even free, hosting options available to WordPress site owners. These can be viable solutions if you don’t have a huge budget. However, when it comes to web hosting, you can often get what you pay for.
If your pages aren’t as fast as they need to be (loading content in just a few seconds), the first thing you should do is contact your hosting provider. There’s a chance they’ll be able to improve your WordPress page speed based on your site’s WordPress settings.
Once thing to check is to make sure they’re running a version of PHP that’s compatible with your website.
If you have an ecommerce site or other online retailer website, consider paying for a dedicated server. It will likely be money well-spent.
3. Choose the right theme
Your WordPress theme is the collection of files that create the unifying design of your WordPress site. It’s your template, basically. Which is probably why these files are called “template files”.
Your WordPress theme can have a big impact on how quickly your site loads, or how quickly it appears to load.
If your WordPress pages have a very high load time, your theme could be an issue.
So it’s advisable to go for a lighter WordPress theme that takes less time to load.
In an ideal world you’ll be able to build your own custom theme or hire a WordPress developer to do it for you. However, that’s not always a possibility. If you’ve already got a theme installed on your WordPress site, you can check it with the Theme-Check plugin.
Theme-Check will give you some helpful tips to get the best performance out of your current them. Warning: you will need to know some PHP to use this plugin.
4. Optimize your caching
Enabling and optimizing browser caching is standard advice when it comes to improving page speed on any website. In case you’re not familiar with caching, it allows a user’s browser to store files locally to load whenever someone revisits a page. This gives your server less to do.
The best way to optimize your WordPress site’s cache is with a plugin. We recommend the W3 Total Cache plugin.
Here’s how to go about optimizing your WordPress site’s cache to improve page speed:
- Once you’ve installed the W3 Total plugin, go to the General Settings:
- Ensure the “Toggle all caching types on or off (at once)” is DISABLED.
- Enable Page Cache
- If you’re using a CDN (more on that in the next section) disable Minify. If you’re not using a CDN, enable it
- Disable the Database Cache and enable Object Cache
- Enable Browser Cache. If you’re using a CDN that has its own plugin or extension, disable CDN here.
- Uncheck all Debug Modes:
- Click on Page Cache on the left side menu:
- Check the boxes for the following options: “Cache posts page”, “Don’t cache front page”, “Cache feeds: site, categories, tags, comments” and “Don’t cache pages for logged in users”
- Scroll down and check the boxes for “Automatically prime the page cache” and “Preload the post cache upon publish events”
- Click on Browser Cache settings on the left side menu
- Check the boxes for “Set Last-Modified header”, “Set expires header”, “Set cache control header”, “Set entity tag (ETag), “Set W3 Total Cache header” and “Enable HTTP (gzip) compression”:
Of course, make sure you saving your settings throughout this process.
5. Why use a CDN?
Keeping all of your website’s files on one server and loading them from there does cause the page’s load speed to slow down. Plus, a user’s physical proximity to your server does impact how long it takes your server to receive a request and respond.
This combines to result in slow pages.
Once solution to this problem is through the use of a content delivery network, also known as a CDN.
A CDN stores certain types of your website’s files on a bunch of different servers around the world. When a user makes a request for one of those files, the CDN is able to load it from the server that is closest to the user’s physical location.
Using a CDN can save your server up to 60% on bandwidth and reduce the number of requests by 65%. So you’ll also save money on top.
This results in a faster page speed for the user.
In fact, using CDN can reduce page load time by up to 50%.
CDNs also have the added value of adding a layer of security to your website. The network’s servers are able to block malicious requests before it makes it to your server.
At the end of the day, you’ll have to decide which option is best for your particular use. Both options can be easily implemented on your site via the W3 Total Cache plugin.
6. Limit the number of plugins
Like with a fancy theme, adding plugins to your site can add fun, cool and useful functionality to your website. Some, like ecommerce and digital goods delivery plugins, are required for your business website to function.
However, each plugin comes with its own set of files that have to load when a user visits your website. Therefore, the more plugins you have, the slower your WordPress site’s page speed becomes.
Some plugins can also interfere with other plugins, which can further degrade page speed and user experience.
So your goal should be to reduce the number of plugins you use on your WordPress site. Generally, you should use a maximum of 15 plugins on your site.
You should also read carefully through all the different functions a plugin can do. There’s no reason to install 3 or 4 plugins when those things can all be done with a single plugin. This might require you to pay for premium plugins, but it will be worth it in the end.
Now that you’ve been warned about excessive plugins, the are some extra WordPress plugins you can consider that are dedicated to helping speed up your site:
That last plugin is particularly interesting. It replaces objects on your page with placeholder files and loads the original file when the user scrolls down the page. Pretty cool.
From an SEO perspective it is possible to overcome slow page speed for your WordPress site and maintain high rankings on the back on highly linked and shared content. However, making sure your pages load as quickly and possible makes it much, much easier.
Fast WordPress pages also make it much, much more likely that your audience is going to stay on your site, engage with your content, convert and then return to convert again.