# Locust

> An open source load testing tool: define user behaviour in plain Python and swarm your system with millions of simultaneous users

Source: https://talira.ai/catalog/locust-ttnvtx2m
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Command-line tool, Library, Web app
- Categories: [testing / load](https://talira.ai/categories/testing/load)
- Platforms: linux, macos, windows, docker, kubernetes[^6][^8][^9]
- Licence: MIT[^5]
- Pricing: Free and open source[^4][^5]
- Pricing notes: Free and open source (MIT). locust.io says a hosted Locust Cloud is in development and locust.cloud offers commercial support; the docs point to Azure Load Testing for hosted runs.
- Free tier: yes[^4][^5]
- Self-hostable: yes[^6]
- Plugins: yes[^7]
- Supports: [llms.txt](https://talira.ai/standards/llms-txt.md)[^10], [OpenTelemetry (OTLP)](https://talira.ai/standards/opentelemetry.md)[^11]
- Creator: Jonatan Heyman, Carl Byström, Joakim Hamrén and Hugo Heyman (original authors)
- Sponsors: Microsoft

Locust is an open source load testing tool where test scenarios are plain Python code: each simulated user runs in its own gevent greenlet, so a locustfile reads like ordinary blocking code and lives in version control next to the service it tests. Tests run from the command line or a web UI that shows throughput, response times and errors live, and results can be exported for later analysis. It runs distributed across many machines for hundreds of thousands of concurrent users, with a [Kubernetes](https://talira.ai/catalog/kubernetes-ftsegx3m.md) operator that manages master and worker jobs, and it can export traces, metrics and logs over OpenTelemetry. HTTP and HTTPS are built in; other protocols are tested by wrapping their Python client libraries. Locust is MIT-licensed and community-maintained; Microsoft sponsors its maintenance, and Azure Load Testing runs Locust tests as a managed service.

## Links

- Website: https://locust.io/
- GitHub: https://github.com/locustio/locust
- Docs: https://docs.locust.io/en/stable/

## Ways to install

### Package managers

- [Homebrew](https://talira.ai/catalog/homebrew-djy17yn9.md): <https://formulae.brew.sh/formula/locust>[^1]
- [APT](https://talira.ai/catalog/apt-d7essv0z.md): <https://packages.debian.org/source/stable/locust>[^2]

## Problems it solves

- load test my API by writing the user behaviour in Python instead of clicking through a GUI
- find out how many concurrent users our web app handles before response times fall apart
- keep load test scenarios in git as normal code our developers can review
- simulate hundreds of thousands of users by spreading the load across several machines
- watch requests per second, response times and failures live in a browser while the test runs
- run a headless load test in CI and fail the build when error rates go up
- reuse our existing Python libraries and test data inside a load test
- model realistic user journeys with logins, waits and conditional steps under load
- load test something that isn't HTTP, like a database or a custom TCP protocol, from Python
- run distributed load tests on Kubernetes without hand-managing master and worker pods
- correlate load test traffic with our traces and metrics in an OpenTelemetry backend
- replace our JMeter XML test plans with Python code
- free open source alternative to LoadRunner for stress testing a website
- stress test an endpoint until it breaks to find our capacity limit before a launch
- spike test a service by ramping users up quickly and back down
- run a load test from the command line with a fixed number of users and spawn rate
- export load test results to CSV for a performance report
- run Python load tests in the cloud without managing our own load generators

## Features

- test scenarios written in plain Python, no GUI or XML
- each user runs in a gevent greenlet, so thousands of users per process
- distributed runs across many machines (master and workers)
- web UI with live throughput, response time and error charts
- headless command-line mode for CI
- CSV export of statistics and history
- built-in HTTP/HTTPS client (HttpUser), with FastHttpUser for higher request rates
- extensible to other protocols by wrapping Python client libraries
- Kubernetes operator with a Helm chart that manages tests as resources
- official Docker images, including one with OpenTelemetry dependencies
- OpenTelemetry export of traces, metrics and logs over OTLP
- can be used as a Python library from your own code
- event hooks and plugins for custom behaviour
- llms.txt and llms-full.txt for AI coding assistants
- runs on Azure Load Testing as a managed service

## Limitations

- Only HTTP and HTTPS are built in: other protocols need their Python client library wrapped in your test code[^3]

## Capabilities

- Has a command line tool: plan not known
- Takes plugins: plan not known
- Has official SDKs: plan not known

## Trust

Overall: 0.40 out of 1.
Signals: backing 0.35, extensibility 0.40.

- created by Jonatan Heyman, Carl Byström, Joakim Hamrén and Hugo Heyman (original authors)
- sponsored by Microsoft
- has a plugin system

Warnings:

- GitHub activity not fetched yet

## Alternatives

- [Gatling](https://talira.ai/catalog/gatling-g21rajx7.md): Modern load testing as code
- [Artillery](https://talira.ai/catalog/artillery-3tg5a71a.md): Full-stack performance and reliability testing: scalable API and Playwright load testing
- [Grafana k6](https://talira.ai/catalog/grafana-k6-76xspfnj.md): Like unit testing, for performance
- [Apache JMeter](https://talira.ai/catalog/apache-jmeter-rh6gkdqd.md): A 100% pure Java application designed to load test functional behavior and measure performance
- [Vegeta](https://talira.ai/catalog/vegeta-td5wyv50.md): HTTP load testing tool and library built to drill HTTP services with a constant request rate

## Sources

[^1]: https://formulae.brew.sh/api/formula.json (checked 21 Nov 2026)
[^2]: https://deb.debian.org/debian/dists/stable/main/source/Sources.xz (checked 21 Nov 2026)
[^3]: https://docs.locust.io/en/stable/testing-other-systems.html (checked 20 Nov 2026)
[^4]: https://locust.io/ (checked 20 Nov 2026)
[^5]: https://github.com/locustio/locust/blob/master/LICENSE (checked 20 Nov 2026)
[^6]: https://docs.locust.io/en/stable/installation.html (checked 20 Nov 2026)
[^7]: https://docs.locust.io/en/stable/extensions.html (checked 20 Nov 2026)
[^8]: https://docs.locust.io/en/stable/running-in-docker.html (checked 20 Nov 2026)
[^9]: https://docs.locust.io/en/stable/kubernetes-operator.html (checked 20 Nov 2026)
[^10]: https://docs.locust.io/en/stable/ai-docs.html (checked 20 Nov 2026)
[^11]: https://docs.locust.io/en/stable/telemetry.html (checked 20 Nov 2026)
