High error rates despite HTTP 200 response codes

A possible cause for high error rates in your JMeter flood

Why your transaction might be failing

During a flood test you may notice that the error rate percentage is high for a particular transaction.

When clicking on the error rate, you may also notice that the HTTP Status Code is 200 OK but the Error Count is greater than 0.​

This can occur for a couple of reasons:

  1. An assertion (e.g. response assertion or duration assertion) has failed.

  2. A sub-sample (e.g. Embedded Resource) has failed.

In the previous screenshot, the error count is 3 and the sample count is also 3, which indicates that all samples failed for that transaction.

Example for Embedded Resource failure

It is a good idea to run your test script locally on JMeter to discover any embedded resource failures, as these are typically not related to load.

You can do this by running your test with a View Results Tree listener, which should be able to identify in red the problem sub sample. In the following example, a HTTP 404 in one of the embedded resources is causing the parent sample to fail.

When clicking on the parent sample, you can see that the response code was an HTTP 200, but the Error Count is 1. This error is due to the sub sample with the HTTP 404.​

Example for Assertion failure

There are a number of different assertions you can apply to the response in JMeter. Some common ones are duration, content, or size assertions. The following example marks the parent transaction as failed because the response size is less than 8,000 bytes.​

Despite the parent sample returning a HTTP 200 OK, the transaction is still marked as failed.​

How to fix failure due to embedded resources

We suggest you