Website load testing shows how many requests per second your site can serve and at what load responses start to slow down or turn into 502 and 504 errors. All you need is a free tool (k6, wrk, hey, Locust), a short scenario that raises the load step by step, and three numbers in the results: RPS, p95 and error rate. Only ever test your own site, and preferably only after telling your hosting provider.
How we tested
On 10 November 2026 on a test bench: Ubuntu 24.04.5 container (2 vCPU, 8 GB RAM), nginx 1.24.0, PHP-FPM 8.3.6, MariaDB 10.11.14, WordPress 6.4.3 with the Twenty Twenty-Four theme and 13 posts (home page 103,728 bytes of HTML). We loaded the site with seven tools (ab, wrk, hey, oha, k6, siege, Locust) in runs of 10-20 seconds: from 5 to 200 concurrent requests, without a cache and with nginx fastcgi_cache, with 4 and 16 PHP-FPM workers. The load generator ran on the same machine, which other jobs were using at the same time (load average 0.5 to 13), so the numbers have some spread. These are test bench figures, not RichHost server data. The k6, wrk2, oha and web.dev documentation was checked the same day.
Safety first: what you may and may not test
Technically, a load test is no different from a small DDoS attack, so the rules are strict:
- Your own site only. Testing someone else’s site can break the law and the provider’s terms. The same goes for third-party resources on your page: payment gateways, analytics, CDNs.
- Tell your host. On shared hosting your site shares a server with other customers. Do not start without a reply from support: send the URL, your IP address, the time and the maximum load. RichHost support works from 10:00 to 20:00 Kyiv time and replies in about 30 minutes, so agree on the test in advance.
- Protection may block you. A WAF, rate limiting or fail2ban will ban an IP that sends hundreds of requests. 403 or 429 responses mean you are testing the protection, not the site.
- Start small and set a stop condition. First run at 1-5 concurrent requests, steps of 30-60 seconds, stop when errors exceed 1% or p95 goes above your threshold. Run cart and form scenarios on a copy of the site.
Our bench breaks one more rule on purpose: the load generator should not run on the site’s server, because it takes CPU away from it. For a real test, use a separate machine in another data center or a cloud service. For example, the free Loader.io plan, according to its pricing page, gives up to 10,000 clients, 1-minute tests and 1 target host (checked 10.11.2026).
Tools: same site, different numbers
One URL, 10 concurrent connections: an uncached page (every request runs PHP and queries the database) and the same page behind nginx fastcgi_cache.
| Tool and mode | Uncached, RPS | Uncached, p95 | Cached, RPS |
|---|---|---|---|
ab -c 10 |
10.1 | 1294 ms | 13,587 |
ab -k -c 10 (keep-alive) |
8.3 | 1479 ms | 12,498 |
wrk -t2 -c10 |
12.2 | none (p99 1570 ms) | 16,809 |
hey -c 10 |
10.7 | 1263 ms | 8,596 |
oha -c 10 |
13.6 | 1123 ms | 13,597 |
| k6, 10 virtual users | 14.9 | 942 ms | 4,147 |
| siege with default settings | 116.6 “transactions” | mean 80 ms | 3,961 |
siege -b --no-parser |
16.8 | mean 580 ms | 4,578 |
| Locust, FastHttpUser | 16.8 | 820 ms | 3,057 |
| Locust, HttpUser | 16.0 | 870 ms | 1,158 |
- When the server is the bottleneck, the tools roughly agree: 10-17 requests per second, and most of that spread was noise on the machine.
- When the server is fast, you are measuring the generator. On the cached page wrk and Locust differed 14 times: Python and JavaScript tools spend more CPU per request than wrk or oha.
- siege tests the wrong thing by default. It parses the HTML and downloads CSS, JS and images: 1463 of 1672 “transactions” were static files, so the result looks 7 times better than reality. For pages, run it with
--no-parser. - keep-alive in ab often does not work. ab speaks HTTP/1.0, while WordPress sends the page without Content-Length, so nginx closes the connection after every response: “Keep-Alive requests: 0”.
- wrk does not report p95, only the 50th, 75th, 90th and 99th percentiles.
Closed and open model: how a tool can hide a problem
ab, wrk, hey and k6 with virtual users follow a closed model: each connection sends its next request only after the previous one is answered. When the server slows down, the generator slows down too, and slow periods enter the statistics as just a few requests. The k6 documentation calls this coordinated omission. Real visitors arrive regardless of whether the server has answered the previous ones. That is the open model, reproduced by wrk2 with -R, by oha with -q and --latency-correction, and by k6 executors such as constant-arrival-rate.
We simulated an outage, such as a heavy backup: at second 8 of a 20-second run we froze all PHP-FPM workers for 4 seconds. wrk2 could not be installed on the bench (the bench network blocks downloading its source), so we reproduced its method with oha’s latency correction:
| Run | Requests | p50 | p90 | p99 |
|---|---|---|---|---|
| wrk, no stall (baseline) | 483 | 406 ms | 508 ms | 705 ms |
| wrk, 4 s stall, default 2 s timeout | 372 | 404 ms | 537 ms | 762 ms |
wrk, 4 s stall, --timeout 10s |
365 | 453 ms | 2.17 s | 4.39 s |
oha -q 8 --latency-correction, 4 s stall |
160 | 87 ms | 2.90 s | 4.10 s |
| k6 constant-arrival-rate 8 per second, 4 s stall | 161 | 80 ms | none (p95 3.41 s) | 4.01 s |
With default settings wrk barely noticed a four-second outage: p99 rose from 705 to 762 ms, and the 10 requests that waited longer than 2 seconds went into the “Socket errors: timeout 10” line and never entered the latency statistics. In the open model 8 new requests arrived every second during the stall, a fifth of all requests were hit, and p95 showed 3.4-3.5 seconds. That is what visitors would have seen. Takeaway: find maximum RPS with a closed model (wrk, hey), judge the visitor experience at a given traffic level with an open one, and always check the timeout line.
Step test: finding the knee
Next we raised concurrency from 5 to 200 (hey, 15 seconds per step, keep-alive on) in three configurations:
| Concurrent requests | 4 PHP workers, uncached: RPS / p95 | 16 workers, uncached | 4 workers, fastcgi_cache |
|---|---|---|---|
| 5 | 23.5 / 0.36 s | 30.3 / 0.22 s | 14,118 / 1.0 ms |
| 10 | 23.9 / 0.71 s | 28.6 / 0.47 s | 15,980 / 2.0 ms |
| 25 | 26.8 / 1.45 s | 22.2 / 1.70 s | 16,943 / 4.7 ms |
| 50 | 28.3 / 2.08 s | 29.3 / 1.91 s | 9,498 / 12.3 ms |
| 100 | 26.6 / 4.68 s | 29.0 / 3.72 s | 9,974 / 27.3 ms |
| 200 | 28.3 / 7.92 s | 27.9 / 7.53 s | 13,041 / 30.3 ms |
| Load average during the series | 3.1-4.8 | 4.4-13.6 | 6.0-12.5 |
There were no errors, but the uncached site stopped scaling at 5-10 concurrent requests: RPS froze at 24-28, and every extra user only made the queue longer. This is Little’s law: response time is roughly the number of concurrent requests divided by throughput. 200 divided by 28 per second gives 7.1 seconds, and the test showed a median of 6.6 and p95 of 7.9 seconds. A repeat series 20 minutes later gave 16 to 28 RPS: neighbouring processes affect the result, just like neighbours on shared hosting.

16 PHP-FPM workers instead of 4 gave almost nothing: both cores were already busy, the queue just moved from the PHP-FPM socket to the CPU run queue, load average rose to 13, and the workers took about 650 MB of RAM. More workers make sense when they wait for the database or external APIs. A page cache changed everything: thousands of requests per second with millisecond latency, and the limit became the generator itself. What else takes load off PHP besides caching is covered in our guide on how to speed up WordPress.
Where 502 and 504 begin
200 concurrent requests passed without errors only because the PHP-FPM queue is long and nginx’s default timeout is 60 seconds. To see errors in short runs, we lowered the limits:
| Setting | Concurrent | Successful | Errors |
|---|---|---|---|
fastcgi_read_timeout 5s |
25 | 277 | 0 |
fastcgi_read_timeout 5s |
50 | 55 | 146 × 504 (73%) |
fastcgi_read_timeout 5s |
200 | 0 | 600 × 504 |
| default 60 s and socket queue | 600 | 230 | 466 client timeouts (30 s) |
listen.backlog = 64 |
50 | 237 | 0 |
listen.backlog = 64 |
100 | 127 | 113,347 × 502 |
The results match our breakdown of 502 Bad Gateway causes. A 504 appears when a request waits in the queue longer than the timeout, and then things collapse: nginx has already returned 504 to the client, but PHP-FPM still renders the abandoned request, so at 200 concurrent requests not a single one succeeded. In the nginx log this is “upstream timed out (110: Connection timed out)”; more in our article on the 504 Gateway Timeout error. A 502 appears instantly when the socket queue overflows: “connect() to unix:…php-fpm.sock failed (11: Resource temporarily unavailable)”. And the most important lesson for reading reports: with a small queue hey showed 7,038 requests per second with p95 of 7.8 ms, because 99.9% of responses were fast 502s. Without a status code column this looks like a record.
On shared hosting, instead of 502 or 504 you may get a 508 Resource Limit Is Reached error: the plan’s process or CPU limits have kicked in.
Metrics: what each one means and what is normal
| Metric | What it means | Normal for a website |
|---|---|---|
| RPS (requests per second) | How many responses the server returns per second | No universal norm. Rule of thumb: at least twice your analytics peak, and only together with the error rate |
| p50 (median) | Response time half of the requests beat | Close to a single request’s time without load (62 ms on the bench). Several times higher: requests are queuing |
| p95, p99 | The tail: every 20th and every 100th request is slower | For HTML at expected peak up to 0.8 s. Above 1.8 s is poor (web.dev TTFB thresholds) |
| Error rate | 5xx and 4xx responses and client timeouts | 0 at expected load, 1% as a stop condition (example from the k6 docs). Check timeouts separately: wrk leaves them out of latency |
| Cache hits (X-Cache: HIT) | How many pages were served without PHP | Almost all HIT for anonymous visitors’ pages. MISS on every request: the cache is not working |
| Load average, CPU, server RAM | Whether the server is hitting resource limits | Load average not above the core count for long, no 508 and no OOM messages in the logs |
The web.dev thresholds (0.8 and 1.8 seconds) are defined for time to first byte, but they are a handy guide for HTML under load.
A safe k6 scenario, tested on the bench
The script uses the open model: the request rate grows from 2 to 40 per second, and thresholds with abortOnFail stop the test by themselves when p95 exceeds 800 ms or errors exceed 1%. Put real pages of your site into PAGES, including the ones the cache does not cover: search, cart, filters.
import http from 'k6/http';
import { check } from 'k6';
const BASE = __ENV.BASE || 'https://example.com';
const STEP = __ENV.STEP || '30s';
const PAGES = ['/', '/bench-post-3-about-load/', '/?s=load'];
export const options = {
scenarios: {
ramp: {
executor: 'ramping-arrival-rate',
startRate: 2, timeUnit: '1s',
preAllocatedVUs: 20, maxVUs: 200,
stages: [
{ target: 5, duration: STEP },
{ target: 10, duration: STEP },
{ target: 20, duration: STEP },
{ target: 40, duration: STEP },
],
},
},
thresholds: {
http_req_failed: [{ threshold: 'rate<0.01', abortOnFail: true, delayAbortEval: '5s' }],
http_req_duration: [{ threshold: 'p(95)<800', abortOnFail: true, delayAbortEval: '5s' }],
},
};
export default function () {
const url = BASE + PAGES[Math.floor(Math.random() * PAGES.length)];
const res = http.get(url, { timeout: '30s' });
check(res, { 'status 200': (r) => r.status === 200 });
}
On the bench we ran it with shorter steps:
k6 run -e BASE=http://127.0.0.1:8161 -e STEP=8s k6_ramp.js
...
http_req_duration
✗ 'p(95)<800' p(95)=886.27ms
http_req_failed
✓ 'rate<0.01' rate=0.00%
level=error msg="thresholds on metrics 'http_req_duration' were crossed; at least one has abortOnFail enabled, stopping test prematurely"
The test stopped itself at second 30, when the target rate was approaching 35 requests per second, just above the uncached site’s limit (exit code 99: thresholds failed). Meanwhile, watch the error log in a second terminal:
tail -f /var/log/nginx/error.log | grep -E "upstream timed out|Resource temporarily|Connection refused"
In a hosting control panel, domain logs are usually next to the domain; what to look for in them is covered in our guide to server access and error logs. Repeat the test 2-3 times and take the median.
Reading the results: if X, do Y
| What you see | What it means | What to do |
|---|---|---|
| RPS flat, p95 grows with the number of users | The server is saturated, requests are queuing | Page cache, fewer heavy plugins. More PHP workers will not help if the CPU is at 100% |
| RPS suddenly hundreds of times higher, tiny latency | Fast errors, usually 502 | Check status codes and the nginx log before drawing any conclusions |
| 504 after the same number of seconds | The request waited longer than the timeout | Look for slow code and database queries instead of raising the timeout |
| 508 or a resource limit message | Shared hosting plan limits kicked in | Caching, optimisation, then a different plan |
| CPU of the generator machine at 100% | You are measuring the tool, not the site | A lighter tool (wrk, oha) or several machines |
| Runs differ by more than 20-30% | Noise: neighbours, network, generator | 3 repeats, median, test at the same time of day |
If your site is already slow, start with diagnosing hosting problems. If caching is in place and your analytics peak still hits the limits, compare hosting plans by resources.
FAQ
Can I run a load test on shared hosting?
Only after agreeing with support and with moderate load: an aggressive test hurts your server neighbours, and the provider’s protection may block your IP address.
How many visitors can my site handle if the test showed 25 RPS?
RPS is not the number of people online. If a visitor opens a new page every 20 seconds on average, 25 requests per second is roughly 500 people at once. This estimate covers HTML pages only: static files, cart and search load the server differently.
Which tool should I choose?
For a quick check of one URL, hey or wrk; for a multi-page scenario with thresholds and an open model, k6; Locust suits Python teams. Only compare runs of the same tool with the same settings.
Why does the home page handle thousands of requests while the site falls over during a sale?
The home page comes from the cache, while the cart, search and account pages do not. On the bench the cached page handled over 9,000 requests per second, uncached 24-28. Test uncached pages separately.



