Run the load test and read results
With your load profile and checks in place, you’re ready to run the test and interpret the output. The k6 summary is dense with metrics, but for establishing a baseline you need to focus on a few key lines: http_req_duration for latency, http_req_failed for error rate, and checks for correctness.
To run your test and read the results, complete the following steps:
Open your terminal and run the test:
k6 run baseline.jsk6 displays real-time progress as the test executes, showing the current VU count and completed iterations.
When the test completes, review the summary output. Focus on the following metrics:
http_req_duration: The time it takes for requests to complete. The summary shows several aggregations:http_req_duration..: avg=180ms min=95ms med=165ms max=850ms p(90)=280ms p(95)=350msavgis the mean across all requests, but averages hide outliers.p(90)andp(95)are more useful for baselines. Thep(95)value means 95% of requests completed within that time. The remaining 5% were slower.- If
maxis dramatically higher thanp(95), a small number of requests are experiencing significant delays.
http_req_failed: The percentage of requests that returned a non-2xx status code:http_req_failed................: 0.00% 0 out of 1200The output shows how many requests failed out of the total. For a healthy baseline, this value should be at or near 0%.
checks: The pass rate across all your check assertions. The checks section appears at the top of the summary under TOTAL RESULTS:checks_total.......: 2400 10.00/s checks_succeeded...: 100.00% 2400 out of 2400 checks_failed......: 0.00% 0 out of 2400 ✓ status is 200 ✓ response body is not emptyA 100%
checks_succeededrate means every response met your correctness criteria. The individual check names are listed below with ✓ or ✗ indicators.iterations: The total number of times the default function executed:iterations.....................: 1200 10.00/sThe per-second rate represents your throughput (requests per second) during the test.
Confirm that your test ran cleanly: checks are passing, the error rate is near zero, and the latency values are stable. If something looks off, such as high error rates, check failures, or erratic latency, investigate before using these numbers as your baseline.
Note
Percentiles are more reliable than averages for baselines. An average of 200 ms could mean most requests took 150 ms but a few took 2 s. The p95 value gives you a much clearer picture of actual user experience.
In the next milestone, you identify the specific values from these results to record as your baseline.
Please tell us what didn't work: