The 10 most important parameters of your WordPress performance

Torben Simon Meier Last updated 29.03.2021
10 Min.
WordPress  Performance: The 10 most important levers
Last updated 29.03.2021

The web is teeming with tips and tricks on how to optimize your WordPress performance. Unfortunately, the optimization measures are not always well explained and their relevance is often ignored. We show you the important starting points and tools – in a sensible order and with context. This way you can see results quickly.

So far, we've already hosted about 15,000 WordPress projects. A whole lot of data has accumulated in the process. And we're constantly being asked by customers how they can further reduce the page load time of their WordPress projects. So we've systematically analyzed the results of customers' sites over the last few years. The result: 10 measures with which you can quickly and easily optimize your WordPress performance.

One thing in particular is important: Some users are quickly put off by optimization suggestions from tools like Google PageSpeed Insights. Let me tell you: You won't gain the most loading time with complicated optimization measures, but with methods that are easy to implement.

WordPress performance optimization suggestions by Google
Not all site operators would know what to do with a message like this. That's why it's important to concentrate on simple optimization steps first and tackle the more complicated measures later on.

Of course, load time optimization is not an end in itself. Besides a better experience for your users, a shorter load time also brings advantages in the visibility of your offer in Google. Therefore, I will also briefly outline what the individual optimization steps are actually about in order to create the appropriate context.

Theoretically, you can work your way down from the top to the bottom and thus improve the loading time of your site step by step. By the way, the first seven points also refer to the typical suggestions for improvement from Google PageSpeed Insights, which we go into in more detail in this article, for example.

#1 Caching: the absolute No.1 performance factor

Caching means your site doesn't have to first be requested from the webserver by the browser and then put together bit by bit. Instead, your site is loaded, i.e. completely rendered, from temporary storage.

The benefit of caching is obvious: WordPress doesn't have to build up your site new every time you open a page. As WordPress is based on PHP, which is quite slow, a cache is essential. Among other things, a cache prevents PHP from needing to be read.

In principle, there are two ways to implement a cache:

  • About cachingPlugins: The majority of users use a cachingPlugin, such as W3 Total Cache or WP Super Cache. These are sometimes easier, sometimes a bit more complicated to set up. In any case, a certain amount of manual work is required here.
  • About host : Some host - including RAIDBOXES - offer server-side caching. This means that you can almost always do without cachingPlugins . Because your hosting provider has already taken over the configuration of the cache for you.

If you have set up a performant caching, you have already taken the most important step towards more WordPress performance. For more details, take a look at our article on caching basics.

#2 Tidying up WordPress

In our experience, one of the most common causes for long loading times is an overloaded WordPress installation. And because this point isn't mentioned by Google PageSpeed Insights, it takes second place in my list of improvements.

An overloaded WordPress installation usually means there are too many plugins installed. Generally speaking, the fewer the plugins, the faster the site. It goes without saying that plugins are important and you can't do without them entirely. But you should always check from time to time which plugins you really need and which ones you can delete.

Note: make sure you delete extra plugins completely and don't just deactivate them.

Improve WordPress performance: Your plugin overview shows you exactly how many plugins you have installed, activated and still have to update.
Your plugin overview shows you exactly how many plugins are currently disabled. In principle, the number of "inactive" should always be zero. If not, ask yourself whether you really need that deactivated plugin?

The same applies to deleting themes: you don't need more than one.

Why should you delete extra plugins and themes? Because they add PHP code to your site. And this also applies to disabled plugins. More PHP code makes your site overall bulkier and thus slower (and more vulnerable to attacks). As I mentioned earlier, PHP is a very slow scripting language. The less of it there is, the better.

Often, no longer needed Plugins and Themes are leftovers from functional and design tests. Therefore it is a good idea to clean up your WordPress sites regularly and to test new functions and designs in a test environment and not on the livesite . This way, you can avoid accumulating too many Plugin remnants in the first place.

#3 Images: the underestimated speed breakers

One of the most effective and easiest measures to reduce page load time is to reduce the size of images. Because here you can sometimes save large amounts of data. With the so-called "lossless image compression", the file size of your images is reduced without any visible loss of quality. This means that your site hardly changes, while at the same time you can significantly reduce its size through image optimization.

HTTP Archive estimates that images regularly make up the largest portion of a website's traffic. Reducing the size of your images should therefore be one of the first optimization steps. You can either do image optimization manually, or you can use a compression tool Plugin.

Using plugins is certainly the more convenient solution. Not only do plugins allow you to compress new pictures and their thumbnails, they also automatically optimize all existing pictures from your site. However, this service is often subject to a fee.

#4 CSS and JavaScript: sounds complicated but optimization is easy

The second-largest amount of your site data is usually JavaScript and CSS files. Many users are reluctant to make any changes here. But even without code expertise, you can easily understand what CSS and JavaScript optimization is all about. There are basically three things that can be done:

  • Summarize: CSS and JavaScript are hidden in many small individual files. Normally, each of these files must be requested individually by the browser from the web server. This generates HTTP requests that tend to increase the load time of your site . However, if scripts are combined, then the number of files to be loaded is reduced and thus the number of requests. For example, 53 individual requests become just over a dozen. Of course, Pluginscan also do this for you.
  • Reduce: CSS and JavaScript files are lines of code that enable certain features and designs on your site . This code is written by humans. However, it is read by machines. Why is this relevant? Much of what a human needs to understand code correctly, a computer does not. So spaces, comments, etc. are not needed for your site to be built correctly. This is where Plugins like Autoptimize come in. They convert CSS and JavaScript from human-readable to machine-readable code. This makes the individual data packets smaller and their transmission faster.
  • Compress: After summarizing and reducing, the final step is then compressing the data packets that are sent from the web server to the browser. This means that the server minimizes the file size of the individual requests and the browser unpacks and calculates them. This is faster than sending uncompressed data packets. You can set up such a GZIP compression for example via caching-Plugins, via manual settings in the .htaccess or your host has already activated a compression on the server side.

Even without knowledge of the scripts, it is easy to understand what the individual measures bring. And for all three steps there is Plugins, which allows even laymen to optimize CSS and JavaScript. In our article on CSS and JavaScript optimization, we explain more details and present various Plugins .

There we go!

These were the four areas where our customers were able to save a significant amount of loading time. With relatively little effort, you can improve your WordPress performance with caching, image optimization, optimizing CSS & JavaScript, and cleaning up WordPress.

#5 Good hosting is the backbone

The first four optimization fields promise a particularly high load time reduction, but can come to nothing if your hosting slows you down. This does not so much refer to the hardware requirements for WordPress , but rather to certain technologies that show you that host enables you to optimizeWordPress accordingly.

As a rule of thumb, you should expect performant WordPress hosting to offer the following:

  • SSD hard disk
  • PHP memory limit of at least 64 MB, preferably 128 MB
  • Reliable data centers
  • Current PHP version (7.4)
  • HTTP/2 and free SSL certificate

Then there's the difference between shared hosting and separate (virtual) servers.

With shared hosting, you share the server and its computing power with other sites. Usually, this is a few dozen to a few hundred. If you have your own server, you don't have to share the computing power with anyone. Above all, it offers the advantage of performance reliability.

Although your own server doesn't automatically mean more performance, experience shows that cheap hosting plans in particular, i.e. those only costing a few euros per month, can't compete with virtual servers in terms of performance.

The finer points - less clout and more effort

Virtually every WordPress user could optimize the performance-relevant areas I've mentioned so far. Either with plugins, simple testing, or buying the appropriate products. It gets more complicated once you've optimized these areas. Because then you have to go deeper into the site structure. And individual optimization steps no longer have as much effect on your site performance.

#6 Render blocking: wrong loading order

One point that performance optimization tools like Google PageSpeed Insights repeatedly criticize is a loading order that blocks the rendering.

An example to illustrate the issue: A slider consists of images and the animation command that makes these images rotate. If the JavaScript command is loaded first and then images after, your site has a functioning slider but no images. So loading the site takes longer. You can prevent this state with the correct loading order.

While there are ways to optimize the loading sequence with plugins, our experience shows these aren't always able to fully optimize your site. Best results are usually achieved here by a web designer familiar with the functions of the website.

#7 Above the fold: optimizing the visible area of the site

In addition to the total loading time of your site , the perceived loading time is particularly important. This is the time that a visitor to your site perceives as loading time. This perceived loading time can be shortened with a few tricks. Thus, a user gets the impression that the site is already completely built up, although calculations are still being carried out in the background.

Particularly important to optimizing this area, known as Above the Fold, is optimizing the loading order. This means prioritizing content and features that you want your visitors to see on the first screen size.

WordPress  Performance: Illustration of the "above the fold" area of raidboxes.io
The upper area is displayed to the visitor of raidboxes.de without scrolling. This is the so-called Above the Fold. For all further information the visitor has to interact with the site and scroll.

You can achieve this, for example, by optimizing the charging sequence. However, there is also Plugins, which ensures that your site charges more efficiently. And only the visible area. Lazy Load or a3 Lazy Load are examples of such Plugins. This way, the user always gets all the content he or she needs, but the page load time can still benefit from this, especially if it is an image-heavy site .

#8 Cleaning up your database

Besides images and scripts, your database can also get too big. There are also practical tools that keep your database nice and lean. For example, the Plugin WP-Optimize.

#9 Pingbacks and trackbacks

By default, WordPress interacts with other sites that allow pingbacks and trackbacks. Every time your site or one of your blog posts is mentioned, you will automatically be notified – and this fills your database even further.

If you don't need this feature, and the added value is negligible in my opinion, you should disable pingbacks and trackbacks. Again, with the plugin WP-Optimize. Full disclosure here: this is more of a theoretical problem. None of our customers have had any serious performance losses as a result.

#10 Prevent hotlinking

Hotlinking means that someone links directly to an image on your server - effectively "stealing" your bandwidth. On an Apache web server, you can prevent hotlinking by adding the following code to your .htaccess file:

RewriteEngine on

RewriteCond %{HTTP_REFERER} !^$

RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?deineseite.de [NC]

RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?google.de [NC]

RewriteCond %{HTTP_REFERER} !^http(s)?://(www.)?google.com [NC]

RewriteRule .(jpg|jpeg|png|gif)$ – [NC,F,L]

To prevent hotlinking on an NGINX server, add these lines of code to your NGINX config file:

location ~ .(gif|png|jpeg|jpg|svg|webp)$ {
     valid_referers none blocked server_names
	 *.example.com example.* www.example.org/galleries/ ~\.google\.;
     if ($invalid_referer) {
        return 403;
    }
}

Breakdown of the code:
location ~ .(gif|png|jpeg|jpg|svg|webp)$ {
Specifies the file extensions you want to protect from hotlinking. For example, if you still want to protect pdf files, the line of code would look like this:
location ~ .(gif|png|jpeg|jpg|svg|webp|pdf)$

{valid_referers none blocked server_names
*.deineseite.dedeineseite.de ~.google. ~.bing. ~.yahoo.;
These lines are quite long but it will help you better understand what can be done with this rule. These lines indicate which domains are allowed to hotlink your files. In this example example.com with all subdomains, as well as Google, Bing and Yahoo.

if ($invalid_referer) {
return 403;
}
If a request comes in and the requested resource is NOT on your whitelist, the server will return a 403 (Forbidden).

Other methods to prevent hotlinking

There are numerous security Plugins in the official WordPress plugin directory that you can use to prevent hotlinking - for example All In One WP Security & Firewall. The Plugin is active on over 900,000 WordPress websites and has an average rating of 4.8 out of 5 stars (with over 1,000 reviews). Also, you can prevent hotlinking via the CORS headers in your BOX settings. If you have any questions about the header config of your BOX , feel free to contact us in support.

"And what about a CDN?"

One of the most frequently asked questions is about a Content Delivery Network (CDN). For example: "Does a CDN make my site faster for visitors in Germany?", "Why do I actually need a CDN?", "Would you recommend me to use a CDN for my blog or shop?". But in most cases the answer was: No.

To cut a long story short: a CDN makes the most sense if your users are geographically dispersed. For example, if you have customers in Central Europe, South America, and Australia. If your core target group is limited to one country, however, you can forget about using a CDN to optimize your WordPress performance.

By the way, the WordPress developer Ernesto Ruge has written a very nice article about this problem, which I can only recommend to you.

Conclusion: don't shy away from optimization steps that only appear complicated

WordPress users are often afraid to touch areas where, in reality, changes would be quite easy to make and would usually lead to better performance. Or they neglect these areas entirely. In contrast, things like CDNs come up again and again during consultations, even though they often don't have any effect on loading time at all.

That's why I really recommend going for the "low-hanging fruit" of optimization first. With relatively little effort, you can already make great progress in reducing your load time. Even if you're new to WordPress.

So don't be discouraged by advice and suggestions from tools like PageSpeed Insights.

At its heart, performance optimization is covered by only a few areas:

  • Reducing the size of your site
  • Reducing HTTP requests
  • Compressing the individual data packets
  • Optimizing the user experience

Once you've taken this in, you can start pulling the 10 most important levers of WordPress performance we talk about above. For more complex optimization steps, there are also experts who can bring your site performance up to scratch.

Comments on this article

Post a comment

Your email address will not be published. Required fields are marked with *.