# How to load test a website: test types, user numbers and a step-by-step plan

[Insights](https://www.supervisor.com/insights)

## How to load test a website before a traffic peak

A practical guide to load testing a website or online shop before a campaign, a sale or a launch: which kind of test to run, how many users to test with, what usually breaks, and whether to test yourself or buy a managed test.

[Download as Markdown](https://www.supervisor.com/insight/how-to-load-test-a-website.md)

A load test sends many users to a website at the same time and measures what happens: how many it handles, how fast the pages stay, and where it breaks. Run one before the day the traffic comes, whether that is a campaign, a ticket sale, Black Friday or a launch. A site that is fast for five visitors can fail at sixty, and nothing in normal use tells you where that limit is.

This guide covers which kind of test to run, how many users to test with, how to run the test step by step, what usually breaks, and when to buy a managed test instead of running one yourself.

## Which kind of test stops a site from crashing?

Four kinds of test are usually named. They differ in how the load is shaped over time.

|     | What it does | The question it answers |
| --- | --- | --- |
| **Load test** | Ramps up to the number of users you expect and holds it | Does the site handle the traffic we expect? |
| **Stress test** | Keeps adding users until the site fails | Where is the limit, and what breaks first? |
| **Spike test** | Jumps from a few users to many at once | What happens when everyone arrives in the same minute? |
| **Soak test** | Holds a steady load for hours | Does the site slow down over time, for example from a memory leak? |

To keep a site from crashing under high traffic, start with a stress test: it tells you the limit. Then run a load test at the number you expect, plus headroom, to show the site holds it. If your traffic comes in bursts, as with ticket sales or a product drop, add a spike test.

## How many users should you test with?

Test with the number of users who are on the site **at the same time** at the peak, not the number of visitors a day.

A rule of thumb from your analytics:

> Concurrent users ≈ sessions in the busiest hour × average session length in minutes ÷ 60

For example, 3,000 sessions in the peak hour with an average session of 4 minutes gives about 200 users on the site at once. Use last year’s campaign or sale day if you have one. Then add headroom: a target of 1.5 to 2 times the estimate covers a campaign that goes better than planned.

Bursts need a different estimate. When a ticket sale opens at 10:00, most buyers arrive in the first minutes, so the concurrent number can be close to the number of buyers who are waiting.

1.  **Pick the paths that matter.** For an online shop that is the product pages, search, the basket and the checkout. A test that only loads the home page tests the cache, not the shop.
2.  **Choose a time and tell the people who need to know.** Test against production or a copy that matches it: the same server sizes, database, cache and content delivery network. Run outside your busiest hours, and warn your hosting provider and anyone who watches the alerts.
3.  **Check the limits in front of the site.** A firewall, bot protection or rate limit may block the test traffic, which then shows as “Too many requests” rather than as a slow site. Decide whether to let the test traffic through or to test the protection too.
4.  **Run a baseline.** Ramp up until the site slows down or fails, and write down the number of users it handled.
5.  **Read the result together with the server’s logs.** The test shows what failed and when: which pages slowed down and at what number of users. The logs show why: slow queries, full connection pools, errors from an external service.
6.  **Change one thing and run the same test again.** Compare the number of users handled. If you change two things at once, you won’t know which one helped.
7.  **Repeat until the target holds,** then run once more at the target plus headroom.
8.  **Test again after big changes,** or schedule a regular test so a slower release is noticed before the next peak. Between tests, [performance monitoring](https://www.supervisor.com/insight/website-performance-monitoring) tells you when the site slows down or breaks.

## What usually breaks under load?

The causes are usually small, and most of them don’t show with a few visitors.

*   **Slow database queries.** A missing index makes a query take seconds under load. The query holds a connection open, and every page behind it waits. In our [ticket shop case](https://www.supervisor.com/use-cases/ticket-shop-load-test), queries against one table took 10 to 16 seconds under load until a single index was added.
*   **Pools and limits left at their defaults.** Database connection pools, web server workers and thread limits are often set for a small site.
*   **Pages that are not cached.** Every visitor rebuilds the same product listing from the database.
*   **Scripts and libraries in the browser.** A script, font or icon library can stall the page when the server is busy, even when the server answers quickly. In the ticket shop case an icon library made pages much slower under load and sometimes stopped them loading. With the index added and the library removed, the shop went from about 60 simultaneous buyers to about 400.
*   **External services.** Payment, search, recommendations and stock checks can be slower than your own site, or limit how many requests they take.
*   **Sessions and baskets.** Locks on session storage or a shared basket table make users wait for each other.
*   **Scaling that is too slow.** Autoscaling that takes minutes to add servers is too late for a sale that peaks in the first minute.

More hardware is often not the answer. When slow queries hold the connections open, a bigger server waits just as long. Measuring after each change is the only way to know what helped.

## Real browsers or HTTP requests?

A request-level tool such as JMeter sends the requests in your script and checks that the server answers. A browser-based test loads each page as a customer’s browser does: the HTML, scripts, styles, fonts, images and API calls, with JavaScript run.

The difference matters for pages that people use. A page can answer with 200 OK and stay blank because its JavaScript failed. A third-party script can stall the page while the server is fast. A request-level test sees neither. It is still the right tool for an API or for very high request volumes. For shops, checkouts, booking and web apps, test with browsers. The [comparison on our load testing page](https://www.supervisor.com/website-load-testing) goes through it point by point.

## Run it yourself or buy a managed load test?

**Run it yourself** when the site is yours to change and you want to test again after each fix. A self-service test needs an address and a target number of users, and the test can be repeated as often as you change something.

**Buy a managed test** when you need more users than a self-service tool allows, when the test needs journeys through logins or a checkout with test payments, or when nobody in the team has time to plan the test and read the results. In a managed test the provider plans, runs and analyses the test and reports what to fix.

**Let an AI agent manage it** when you want the work of a managed test but not its hourly rate. A coding agent that has access to your server can do most of what a performance engineer does: start the test, watch the logs, processes and monitoring tools while it runs, find the cause, make one fix and run the test again to verify it. You approve each change, and the test itself has a fixed price. With Supervisor this is [Autotune](https://www.supervisor.com/autotune#managed), a half-managed service: Supervisor runs the browsers and measures, and your agent does the engineering.

If you plan to run the browsers in your own cloud account instead, [check its CPU quota first](https://www.supervisor.com/compare/real-browser-load-testing-tools#running-it-in-your-own-cloud-check-the-quota-first): a large browser test may need far more than the account allows by default.

Questions to ask a load testing provider:

*   Does the test run real browsers, or send HTTP requests?
*   How many users can one test have, and from where does the traffic come?
*   Can the test follow a journey: log in, add to basket, check out?
*   How is the price set: per test, per user, per hour or a subscription? Is the price fixed before the test starts?
*   What does the report show: users handled, page load times, the slowest pages and requests, server time and browser time?
*   Can the same test be run again after each change, and compared with the last one?
*   How is test traffic marked, so you can tell it apart in your logs and analytics?
*   Do they need to verify that the site is yours?

## How Supervisor load tests a website

Supervisor runs load tests with real browsers. You enter your site’s address and the number of users to reach, and the result is one number: how many users the site handled.

*   **The ramp-up.** The test starts with 4 users and adds users every 10 seconds until the target holds. It stops earlier when the average page load passes the limit, 3 seconds by default, or when 20% or more of the browsers are failing.
*   **The report.** Users handled, average page load, the time 95% of pages loaded within, the slowest pages with server time and browser time, and the slowest requests.
*   **Journeys and controlled tests.** A journey follows named steps such as login and checkout. In a controlled test you add users yourself and can run for up to 2 hours, which is enough for a spike test or a short soak test.
*   **Scheduled tests.** A test can run every day, week or month, and you get an email when the site gets slower than the median of the previous five runs.
*   **Test traffic is marked** with an X-Supervisor-Run header.
*   **Agent-managed tests.** Through [Supervisor Autotune](https://www.supervisor.com/autotune#managed) your agent starts the test, reads the result, the server’s logs and its monitoring, makes one change you approve and runs the test again to verify it.

**Prices.** The first test with 4 users is free and needs no verification. After that a test costs 1 credit per 10 users, and credits are sold in packs from €15 for 10 credits (prices exclude VAT). The price of an automatic test is known before it starts. Self-service tests go up to 1,000 users. For more users, or for a managed test where Supervisor’s people plan, run and analyse the test, [ask for a quote](https://www.supervisor.com/pricing#quote). All prices are on the [pricing page](https://www.supervisor.com/pricing).

To load test a site, it must be yours: you verify it with a DNS record or a file. The [step-by-step guide](https://www.supervisor.com/docs/web-load-test) shows a test in the web app from start to report.

## Related content
- [We load test the wrong way: why JMeter-style load tests miss the real bottlenecks](https://www.supervisor.com/insight/we-load-test-the-wrong-way)
- [Website performance monitoring: what to measure, how often and which alerts to set](https://www.supervisor.com/insight/website-performance-monitoring)
- [European Accessibility Act checklist: EAA compliance checklist for websites and online shops](https://www.supervisor.com/insight/accessibility-checklist-for-the-eu)
- [European Accessibility Act (EAA) compliance: requirements, guidelines and steps](https://www.supervisor.com/insight/european-accessibility-act-compliance)
- [GEO Optimization & Accessibility: Unified SEO Strategy for AI & Humans](https://www.supervisor.com/insight/geo-optimization-and-accessibility-built-on-the-same-foundation)
- [Accessibility statement example and template for websites (EU)](https://www.supervisor.com/insight/how-to-write-your-accessibility-statement)
