Check web server response times with a single terminal command
When you need to know how much load a server can handle, hey sends requests and displays the results with just one line in the terminal. It is a small program that replaces ApacheBench, applying load to web applications and outputting statistical information. You can determine how a server reacts under real traffic conditions without complex configuration.
Reason for the name change
hey originally started under the name boom. However, the name overlapped with another developer's tool, causing confusion due to binary conflicts. The project name was changed to hey to respect the original owner's name. This change was a measure to resolve name collision issues within the open-source community, unrelated to the tool's functionality.
How to run load tests
hey executes a specified number of requests at a specified concurrency level and outputs statistics. The defaults are 200 requests and 50 concurrent workers. You can adjust the number of requests with the -n option and the number of concurrent workers with the -c option. Additionally, using the -z option allows you to limit the test by time, which is useful for measuring performance over specific periods like 30 seconds or 3 minutes. It also supports HTTP/2 endpoints, enabling tests in modern protocol environments.
Configuring various request scenarios
In addition to simple GET requests, it supports various HTTP methods such as POST, PUT, and DELETE.
- Request control Adjust load intensity through request count, concurrency, time limits, and QPS limits.
- HTTP options Configure details of HTTP requests, including method, headers, body, authentication, proxy, and timeout.
- Output format Outputs summary statistics by default, and the
-o csvoption allows saving results in CSV format.
Installation and usage environment
Binaries are provided for the amd64 architecture on Linux, macOS, and Windows. macOS users can easily install it via Homebrew using the brew install hey command. Written in Go, it runs as a single binary with no additional runtime dependencies. After installation, you can start testing immediately by running hey <url> in the terminal.
Pre-usage checks
hey is a load generation tool, so it applies actual load to the target server. It must only be used in test environments or during approved times before running in production. The README does not specify particular operating system versions or Go version requirements, but the provided binaries are limited to the amd64 architecture. If you are using an ARM-based Mac or other architectures, you may need to build directly from source. Additionally, since network bandwidth and server resources affect the test, these environmental factors should be considered when interpreting results.