The first question most people ask before running their own survey server is how big it needs to be. The honest answer depends on how many people answer at the same moment, which is hard to guess. So I stress tested VeySur with simulated participants until the server stopped keeping up, and wrote down what happened.

One detail changes the answer more than any other: what the participant’s browser has already downloaded. A survey link is usually opened by someone who has never seen VeySur, so their browser must fetch the whole survey application before the first question appears. The tests below treat that as the normal case.

This post covers what a small virtual server handled, what the limit turned out to be, and how to convert the results into a number you can compare with your own survey.

What was tested

The test server was a Hetzner CX33: 4 shared vCPUs and 8 GB of RAM, the second cheapest virtual server Hetzner offers. The web server, the application, the database and the cache all shared it, which is what you get if you run everything on one machine. The load came from a separate machine, so generating traffic did not compete with the server for CPU.

This post uses two terms, and they are not the same thing:

  • A response is one participant’s whole trip through the survey, from opening it to finishing. A completed response is one person who got to the end.
  • A request is a single call from the participant’s browser to the server. One response is made up of several requests.

Each simulated participant behaved like a real one. They opened the survey link, downloaded the survey application, signed in, loaded the survey, saved their answers page by page and completed the response. The survey had 12 questions on 4 pages, three questions per page. The browser saves once per page, when the participant clicks Continue, and the last page’s save completes the response. So one response is 6 calls to the API: one to sign in, one to load the survey, and one save for each of the four pages. On top of that comes the page load itself.

A save request is much smaller than a response. It is one page of answers, and it is what the latency figures below measure. The headline rate counts whole responses, so 25 completed responses per second means 150 API requests per second, plus 25 survey application downloads.

Every response was counted afterwards by looking in the database, to check that nothing was lost or saved twice. In the runs reported here, every completed response was there.

Cold sessions: the cost of opening a survey

A cold visit is one where the browser has nothing cached. It downloads 14 files, about 390 KB compressed on the wire (roughly 1.8 MB once unpacked). Most of those files are fingerprinted and cacheable for a year, so a returning participant skips them, but the small entry page is fetched every time. Participants who follow a link from an invitation email or a social post are almost all first visits, so I ran the main tests with every session cold.

That download is not free. Measured on its own, one cold load costs about as much CPU as a good share of a survey’s API calls, so it shapes the results below. A test that leaves it out flatters the server.

The headline result

With every participant cold, the highest rate I proved the server can sustain cleanly is 25 completed responses per second. That is 90,000 completed responses per hour.

At that rate:

  • No requests failed.
  • A save request (one page of answers) took 267 ms at the 95th percentile, well inside the 800 ms limit I set.
  • Downloading the application’s files took 1.44 seconds at the 95th percentile, inside the 2 second limit.
  • The web server used about 63% of its CPU allowance.

I also tried 30 per second with every session cold, and it did not hold. The server completed only about 21 per second, around a thousand participants were dropped, and the slowest file downloads took 15 seconds. Between those two results the true limit for fully cold traffic sits somewhere from 25 to 30 per second. As a planning figure I use about 27 per second, or 97,200 an hour, but that is the midpoint of a pass and a fail, not something I ran. Quote 90,000 an hour as the tested number.

That failure was not the CPU. The server was at 71% on average, and the web server was barely working. The delay was in sending bytes to the load generator: the transfer rate stayed at 9.5 to 9.7 MB per second whatever rate I asked for. My best guess is the network link between the generator and the server, which would mean the server could do more than this result shows. I have not proven that, so I am not claiming it.

A realistic mix

Not every participant is a first-time visitor, and returning people are cheaper. So I also ran 30 responses per second for 30 minutes with half the sessions cold. It passed:

  • 55,044 responses completed, about 108,000 an hour at the steady rate.
  • One failed check out of 220,172, and 0.2% of participants dropped.
  • Server CPU averaged 93% and sat at 95% or above for more than half the time, so there was little headroom. No process restarted and memory settled at 77% afterwards.

If the survey is private or shared with an audience that comes back, expect something between this figure and the all-cold one. If you are mailing strangers, plan on the all-cold figure.

What the API alone can do

To find where the CPU really runs out, I removed the application download and tested the API calls alone. The server stayed within the limits up to 40 responses per second, the highest rate I tried, about 144,000 an hour, with the CPU averaging 87%. Pushing as hard as possible with a ramp reached about 32 per second before four cores were at 99% and a typical save took nearly two seconds. That earlier ramp was a harsher test, so I treat the clean runs as the guide.

The gap between 40 per second and 25 per second is the cost of serving the survey application to cold browsers. That is a reason to put a CDN in front of the static files if you expect large, sudden audiences, since it takes that work off your server entirely.

Editing while people answer

Researchers do not stop editing because a survey is live, so I also ran a mixed test. Participants answered at 20 responses per second (72,000 per hour) while five editors changed the survey about once a second and a new version was published every 15 seconds. This test measured the API only, without the application download.

Nothing failed. Saving an answer took 61 ms at the 95th percentile, an editor’s change 62 ms, and a publish 311 ms. CPU peaked at 60%. Participants who had already started stayed on the version they began with, so publishing mid-survey did not disturb them.

From responses per hour to people online

Responses per hour is not how most people think about load. They think about how many people are answering at once. The two are linked by how long a participant spends in the survey:

people answering at once = completed responses per second x time spent per response

For this 12-question survey at the proven cold rate of 25 responses per second:

Time per question Time per response People answering at once
2 seconds about 25 seconds about 600
5 seconds about 61 seconds about 1,500
10 seconds about 121 seconds about 3,000
20 seconds about 241 seconds about 6,000

Slower participants mean more people online at the same rate of completions, which is why the same server can hold thousands of people reading a long survey. The table counts the work of each response, not the cost of keeping people connected, so treat it as a floor.

Smaller and larger servers

I have only measured the CX33 so far, so I am not going to guess at figures for other sizes. What the results do show is that CPU is the limit for the API and that the work is spread across requests, so adding cores should raise the ceiling and removing them should lower it. How closely it follows is something I will measure and publish here rather than assume.

Caveats before you size a server from this

  • The vCPUs are shared. On a shared plan, other customers on the same physical host can use CPU too, so your throughput may vary from hour to hour. A dedicated-CPU server should be steadier.
  • The test answers were short. Real answers, especially long free-text ones, cost more to validate and store on each save. Treat these figures as a best case for the survey shape tested.
  • Invitations arrive in bursts. If you email a few thousand participants at once, many will click within a couple of minutes, and nearly all of them will be cold. Size for that peak, not the hourly average, and expect it to be several times higher.
  • Your participants’ connections matter. The test downloaded the application over a fast link. Participants on slow mobile connections hold requests open longer, which uses more server connections even though it uses no more CPU.
  • Request limiting was off. Your server will have it on, which protects it from abuse but means a burst from one network address may be slowed down.
  • Survey shape matters. A survey showing one question per page saves more often than one showing groups, and a longer survey sends more data on each save.
  • A mixed workload costs more. Heavy exports and imports running in the background use the same CPU, so schedule them away from your busiest periods.

What to take from this

A budget 4 shared vCPU, 8 GB virtual server completed 25 responses per second from fully cold browsers, 90,000 an hour, with room in the response times, and 30 per second when half the visitors were returning. For most research and internal surveys, that is far more than you will ever need. If you do run a large invitation, check your survey’s length against the table above and leave generous headroom.