What are the VU limits in k6?

Hi all - we’re seeing the test hangs when we set a high number of virtual users. We couldn’t find any limit in the docs, so I wonder can anyone tell me what is the maximum number of virtual users?

(question copied from the slack channel)

There’s no limit in k6 for VU’s. But your hardware has limits :slight_smile: Your machine probably reaches Memory or CPU limit at a certain point. I.e. it depends on the capacity of the hardware you run, and the complexity of your script.

Simple scripts will consume ~1 MB per VU, others may consume 35 MB per VU. If you need to run several thousands of VUs, you can consider Grafana Cloud k6 | Performance testing tool for running your k6 scripts in the cloud, in distributed manner (on multiple servers).

Check Memory and CPU consumption on your machine while k6 is running. You may try to simplify your script to reduce resource consumption.

(answer copied from Slack channel)

3 Likes