Repolode
tsenart

tsenart/vegeta

A command-line tool and Go library for HTTP load testing that sends requests at a constant rate and reports latency statistics.

Open-source alternative to:Apache JMeter

Stars
25,225
Forks
1,428
Open issues
125
Last commit
last month

What is it?

Vegeta is an HTTP load testing tool built to hit HTTP services with a constant request rate. It can be run as a command-line program, where attack, encode, report and plot are separate commands that can be chained together with UNIX pipes, or imported as a Go library to drive load tests from code.

Targets can be supplied as a plain-text list in HTTP message style or as a stream of JSON objects generated by another program, which makes it possible to produce requests dynamically. The attack command controls rate, duration, worker counts, timeouts, TLS certificates, HTTP/2, keep-alive, connection limits and custom DNS resolvers. Results can be summarized as text or JSON, bucketed into histograms, exported as HDR histogram data, or rendered as an interactive HTML latency plot.

Vegeta also exposes a Prometheus exporter during an attack and supports distributed runs by splitting the target rate across several machines and merging their result files.

Key features

  • 01Constant-rate HTTP attacks usable from the command line or as a Go library.
  • 02Targets accepted as a text list or a JSON stream, including lazily generated input.
  • 03Latency reports with percentiles, status code histograms and error sets.
  • 04Text, JSON, histogram and HDR histogram output formats.
  • 05Interactive HTML plot of request latency over time.
  • 06Built-in Prometheus exporter during attacks.
  • 07Supports HTTP/2, TLS client certificates, custom headers and DNS resolvers.

Use cases

  • Measuring how an API endpoint's latency behaves under a fixed request rate.
  • Running distributed load tests by splitting a target rate across several machines.
  • Feeding dynamically generated requests into a service from a script or data pipeline.
  • Monitoring attack metrics in Grafana through the Prometheus exporter.

Quick start

  1. 1

    Install on macOS with Homebrew

    brew update && brew install vegeta
  2. 2

    Install on Arch Linux with pacman

    pacman -S vegeta
  3. 3

    Run a test: send GET requests at 50 per second for 5 seconds and print a report

    echo "GET http://localhost/" | vegeta attack -duration=5s | tee results.bin | vegeta report

Things to know

  • Install scripts and binaries are only listed on the releases page for other platforms, so setup depends on your OS.

In collections

Topics

FAQ

What is vegeta?
A command-line tool and Go library for HTTP load testing that sends requests at a constant rate and reports latency statistics. Vegeta is an HTTP load testing tool built to hit HTTP services with a constant request rate. It can be run as a command-line program, where attack, encode, report and plot are separate commands that can be chained together with UNIX pipes, or imported as a Go library to drive load tests from code.
Is vegeta free to use? What license does it have?
vegeta is open source under the MIT license. Check the license terms before using it in commercial products.
Is vegeta still maintained?
Updated within 6 months. The last commit to vegeta was on Sep 24, 2026.
What can I use vegeta for?
Measuring how an API endpoint's latency behaves under a fixed request rate. Running distributed load tests by splitting a target rate across several machines. Feeding dynamically generated requests into a service from a script or data pipeline. Monitoring attack metrics in Grafana through the Prometheus exporter.
How do I install vegeta?
Install on macOS with Homebrew: brew update && brew install vegeta Install on Arch Linux with pacman: pacman -S vegeta Run a test: send GET requests at 50 per second for 5 seconds and print a report: echo "GET http://localhost/" | vegeta attack -duration=5s | tee results.bin | vegeta report
Where can I get vegeta?
The source code and installation instructions are on GitHub: https://github.com/tsenart/vegeta

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects