Not every web host offers the same level of performance. Many hosting plans return great loading times when you have just a handful of visitors. However, those same hosts can buckle under pressure when your website starts getting more traffic. Fortunately, WordPress load testing helps you precisely determine how much traffic your hosting provider can handle.
In this article, we’ll talk about load testing and how it works. Then, we’ll discuss what you need to run your WordPress load tests and how to interpret the results.
Let’s get to work!
What Is Load Testing and What Does It Measure?
There are several ways to test your WordPress website’s performance. The most popular testing method involves using a service such as GTMetrix or PageSpeed Insights. These platforms enable you to enter a URL and see how long it takes to load on the platform’s end.
Depending on which tool you use, you might get access to different sets of metrics:
Speed testing services can give you a good idea of your website’s performance. However, these tools don’t paint a full picture. Let’s break down why that is:
- You’re only testing page speeds at one point in time. Page loading times can vary drastically from one test to another. That means running a single test will not yield highly accurate results.
- The tests only use one user agent. Page speed testing services emulate a user agent to check your website’s performance. However, there’s a big difference between what happens when one person tries to access your website and when there are multiple people simultaneously.
Every server has a finite number of resources. The system will use some of them to fulfill requests when someone visits your website. The fewer resources your server has, the faster they’ll run out if you start getting a lot of traffic in a small window of time.
Simply put, WordPress load testing enables you to see how your server reacts when you put it under pressure. A load or “stress” test will simulate multiple user agents navigating your website. Then, whichever tool you use will measure how your server responds during that process.
Ideally, your server should hold firm and maintain similar page loading times even as the number of users increases. If loading and response times vary dramatically, this data can point toward a poorly optimized website or server.
What You Need for WordPress Load Testing
You only need a working website and a stress testing tool for WordPress load testing. There are plenty of online services that can emulate multiple users visiting your site and measure results for you. However, many of those tools are either paywalled or too complicated for beginners to use.
With that in mind, one of our favorite tools for WordPress stress testing is Loader.io. The platform is from the same team as the SendGrid email marketing service. Moreover, it offers a free plan that enables you to run tests with up to 10,000 concurrent users:
Besides finding an adequate service, the real challenge with WordPress load testing is determining how many clients you should use. Using too few agents for your test means you’re not stressing the server enough. However, if you utilize too many, even a dedicated server will struggle to keep up:
However, suppose you’re running a massively popular website. In that case, those visitor numbers will be a lot higher, and budget web hosting plans will struggle to keep up.
To put heavy website traffic into perspective, here are a couple of figures:
- Wikipedia could handle approximately 50,000 requests per second, with 300 servers at its peak.
- The often-mentioned Reddit “hug of death” can translate to around ten users per second or 600 visits in a minute.
Six hundred visits per minute over an entire day would equal 864,000 users per day. That traffic would put your website squarely amongst the most popular sites in the world. In other words, that’s not the type of stress that a regular server can handle.
If you’re running a stress test for a regular website or online store, your server should be able to handle a moderate number of users in a small window of time. In our experience, testing for 15 users in a one-minute window will reveal a lot about your server’s performance.
That might seem like a low number. However, 15 users per minute equates to 21,600 visits per day and more than 600,000 per month. If you look at a managed WordPress web host such as Kinsta, a plan that could handle that amount of traffic would cost you around $400 per month:
If you’re getting 15 users per minute, that traffic will put your website squarely in the territory of a resounding success. That number also happens to be the minimum metrics that Loader.io will accept for a stress test.
How to Interpret the Results of Your Load Test
You’ll want to review two key metrics with WordPress load testing. The first is how long it takes on average for users to load the testing page. For the second benchmark, you’ll want to verify if any of the connections timed out:
The average response should be as low as possible. On average, a website should never take more than two seconds to load. After you cross that line, your bounce rate will start to go up dramatically. Therefore, anything less than one second is a stellar loading time for any site.
You’ll also want to look at the response time graph when considering the average. Ideally, the load times should hold relatively steady across the entire test. If there are too many spikes, it means that your server has problems processing requests. Even if some loading times are fast, these peaks translate to poor optimization.
Timeouts usually start to occur when your server is under too heavy a load. In that scenario, the server will begin to drop user requests as they timeout.
If you feel up to it, you can continue to run stress tests with increasing users over a longer period. This method will return more accurate results. However, if your WordPress web host is holding strong with one-minute stress tests, that means that it offers fantastic performance.
In our case, we used a managed WordPress web host for testing. We didn’t start to see spikes in our results until we ran a 100-user one-minute test, which is far more traffic than most websites get:
The big differentiator with a great web host is that the server shouldn’t drop any connections even when response times vary significantly. Likewise, the average response time will remain relatively low.
If your WordPress website is struggling under a moderate stress test, we recommend taking steps to optimize it. You can try some of these methods:
If you’re still getting poor results after optimization, it points to a problem with your hosting plan. At that point, you can choose to upgrade your subscription to handle more traffic or migrate to a better web host.
There are many ways to test your WordPress website’s performance. By combining regular page speed loading time and stress tests, you’ll get the complete picture of how your site responds to traffic. Frequent speed tests show how your website performs under optimal circumstances. In contrast, load tests reveal what happens when you start piling on users.
WordPress load testing is relatively easy to carry out if you have access to the right tools. Loader.io enables you to run free tests with up to 10,000 users per minute, which is a lot more than what most websites receive.
Do you have any questions about WordPress load testing? Let’s talk about them in the comments section below!
Featured Image via Vectorium / shutterstock.com