Jitterbox vs Toxiproxy: HTTP-level failures or TCP-level chaos

Toxiproxy is an open-source TCP proxy that degrades the connection between your app and a real dependency, which makes it the right tool for databases, caches and anything that isn't HTTP. Jitterbox is a hosted fake HTTP API that fails at the protocol level: status codes, Retry-After, broken JSON and LLM stream faults, with a request log and a resilience grade. Many teams can use both.
JitterboxToxiproxy
LayerHTTP (requests and responses)TCP (bytes on a connection)
Works withHTTP APIs: REST, GraphQL, SOAP, LLM APIsAny TCP service: databases, Redis, HTTP
Talks toA fake API (or forwards to the real one)Your real dependency
Status codes and Retry-AfterYes, any status and headersNo
Broken bodiesInvalid JSON, cut-off, empty, wrong typeCut by byte count (limit_data)
LatencyFixed or random rangeLatency with jitter, per direction
Timeouts and hangsYesYes (timeout toxic)
Bandwidth, packet loss, TCP resetNoYes
LLM stream faultsYes (OpenAI and Anthropic formats)No
How oftenAlways, a probability, or a sequenceToxicity (share of connections)
Request log and gradeLive log and resilience reportLogs and Prometheus metrics
Where it runsHosted at jitterbox.devSelf-hosted binary or Docker
License and priceHosted service, free in beta; CLI is MITOpen source (MIT), free

They break different layers

Toxiproxy and Jitterbox both exist to answer the same question: what does your code do when a dependency misbehaves? They answer it at different layers of the stack, and that decides almost everything else.

Toxiproxy is a TCP proxy. You point your app at it instead of at the real service, and it forwards the bytes. Through its HTTP API (port 8474) you attach "toxics" to a proxy: add latency, throttle bandwidth, drop packets, reset the connection, stop after a number of bytes. It doesn't know or care whether the bytes are MySQL, Redis or HTTP. Shopify has used it in its development and test environments since 2014.

Jitterbox is a fake HTTP API. You point your app at a URL like https://<projectKey>.jitterbox.dev, and it answers with the responses you set up. Failure scenarios then make those answers slow, flaky or broken on purpose, at the HTTP level: a 503, a 429 with Retry-After, invalid JSON, a cut-off body, or an LLM stream that stops halfway.

So the question isn't which tool is better. It's which layer your failure lives in.

What each one can break

Failure Jitterbox Toxiproxy
500, 503, any status code Yes No
429 with Retry-After Yes No
Invalid, empty or cut-off JSON body Yes Partly: limit_data closes after N bytes
Fixed or random latency Yes Yes, with jitter, per direction
A hang that ends in a timeout Yes Yes (timeout toxic)
Connection reset No Yes (reset_peer)
Low bandwidth, packet loss, sliced packets No Yes
Service down Yes, as an error response Yes, by disabling the proxy
LLM faults: slow first token, stream cut, malformed chunk Yes, in OpenAI and Anthropic formats No
GraphQL errors and SOAP faults Yes No
Databases, caches, queues No Yes

The pattern is clear from the table. Toxiproxy is the stronger tool for network conditions (bandwidth, packet loss, resets) and for anything that isn't HTTP. Jitterbox is the stronger tool for protocol-level failures, the kind where the server answers but the answer is bad. A TCP proxy can't turn a 200 into a 429, because it never parses the response.

Control and repeatability in tests

Both tools are built for tests, so both let you decide how often a failure happens.

In Toxiproxy, each toxic has a toxicity value: the probability it applies to a connection (1.0 by default). Some toxics carry their own randomness, like jitter on latency. You add and remove toxics around the code under test, for example with the Ruby client's apply block, or reset everything with POST /reset.

In Jitterbox, each rule in a scenario fires always, with a probability, or on a sequence such as "fail twice, then succeed". The sequence counter can be reset between test runs, X-Jitterbox-Seed makes random rolls repeatable, and X-Jitterbox-Fault forces a specific fault on a single request. Every decision shows up in the request log with the reason ("sequence step 2/3 = fire"), and the resilience report grades how your client reacted: did it retry, back off, respect Retry-After, keep its idempotency key, give up eventually.

That last part is the main difference in what you get back. Toxiproxy reports what it did to the connection (logs and Prometheus metrics); whether your client coped is up to your own assertions. Jitterbox records each attempt and checks retry behavior for you.

Running it

Toxiproxy runs where you run it. It ships as a binary for Linux, macOS and Windows, as system packages, and as a Docker image on GitHub Container Registry. In CI you start it as a service container or background process, create proxies (in bulk with POST /populate), and change your app's connection settings to go through them. Its API is unauthenticated by default, so the README recommends TOXIPROXY_AUTH_TOKEN if other machines can reach it.

Jitterbox is hosted, so there's nothing to start. You set your app's base URL for an API to the project's URL, usually through an environment variable. In CI, npx jitterbox run --scenario "<name>" -- npm test switches a scenario on, runs your tests with JITTERBOX_BASE_URL set, switches it off, and fails the build on a bad grade. There's also a GitHub Action. See Jitterbox in CI.

The trade-off is real. Hosted means test traffic goes over the internet to jitterbox.dev, and during the beta there are limits: 500 mock requests a day, 1 project, 10 endpoints and 2 scenarios. Toxiproxy has no such limits, and everything stays on your machine or runner.

When Toxiproxy is the better choice

  • The dependency isn't HTTP. Databases, Redis, message brokers, anything that speaks its own protocol over TCP. Jitterbox can't help here.
  • You want to test against the real dependency. Toxiproxy degrades your actual MySQL; Jitterbox replaces an API with a fake.
  • The failure is the network itself: low bandwidth, packet loss, a peer that resets the connection, data sliced into tiny packets.
  • Everything has to stay local or offline, with no external service in the test path.
  • You want free, open source and battle-tested. Toxiproxy is MIT licensed, with client libraries in many languages, and Shopify has used it in its development and test environments for over a decade.

When Jitterbox is the better choice

  • You're testing how your code handles HTTP responses: 429 with Retry-After, 503 that clears up, 400 that must not be retried.
  • You call LLM APIs. Jitterbox speaks OpenAI and Anthropic formats, streaming included, and can stall the first token or cut a stream partway. See LLM failure testing.
  • You don't have a sandbox for the real API, or it can't be made to fail on demand. Jitterbox gives you a fake one in minutes, from scratch, from an OpenAPI file or by recording the real API.
  • You want the grading done for you, with a request log that shows each attempt and a CI check that fails on bad retry behavior.

Using both together

They don't compete for the same job, so plenty of setups use both. A typical split: Toxiproxy in front of the database and cache in your test environment, Jitterbox standing in for the third-party HTTP APIs, like payments or an LLM provider. One test run can then cover a slow database and a rate-limited payment API, each broken by the tool that understands it.

To try the HTTP side, see how Jitterbox works or create a free project and point one API client at it.

Questions people ask

Can Toxiproxy return an HTTP 500 or 429?

No. Toxiproxy is a TCP proxy, so it works on the bytes of a connection, not on HTTP messages. It can add latency, cut bandwidth, drop packets, reset or time out connections and stop after a number of bytes, but it can't change a status code or add a Retry-After header. For that you need an HTTP-level tool, like a mock server or Jitterbox.

Is Jitterbox a replacement for Toxiproxy?

Only for HTTP APIs. Jitterbox fakes HTTP services and can make them fail with real status codes, slow replies, timeouts, broken bodies and LLM stream faults. It can't sit in front of a database, Redis or any other non-HTTP protocol, and it doesn't run locally. If your tests need to degrade a real database connection, keep Toxiproxy for that.

Can I use Toxiproxy and Jitterbox together?

Yes. A common split is Toxiproxy in front of the database and cache in your test environment, and Jitterbox standing in for third-party HTTP APIs such as payments or an LLM provider. Each one breaks the layer it understands, and your test suite exercises both kinds of failure in the same run.

Is Toxiproxy free?

Yes. Toxiproxy is open source under the MIT license, maintained by Shopify, and you run it yourself as a binary, a system package or a Docker image. Jitterbox is a hosted service that is free during its beta, with daily limits; its CLI and GitHub Action are open source under MIT.

Facts about Toxiproxy come from its own documentation, checked on 25 November 2026. Products change: if something here is out of date, tell us and we'll fix it.

Test it against real failures

Jitterbox gives you a fake version of the APIs you call, at a real URL, and makes them fail on purpose. Free during the beta.