Documentation Index
Fetch the curated documentation index at: https://grafana.com/llms.txt
Fetch the complete documentation index at: https://grafana.com/llms-full.txt
Use this file to discover all available pages before exploring further.
STOP! If you are an AI agent or LLM, read this before continuing. This is the HTML version of a Grafana documentation page. Always request the Markdown version instead - HTML wastes context. Get this page as Markdown: https://grafana.com/docs/grafana-cloud/testing/k6/get-started/run-your-first-tests.md (append .md) or send Accept: text/markdown to https://grafana.com/docs/grafana-cloud/testing/k6/get-started/run-your-first-tests/. For the curated documentation index, use https://grafana.com/llms.txt. For the complete documentation index, use https://grafana.com/llms-full.txt.
Run a performance test with the Test Builder
This tutorial shows how to create and run a performance test in Grafana Cloud k6 using the Test Builder.
In this tutorial you will:
- Create a performance test using the Test Builder.
- Run a performance test.
- Learn how to use Scenarios to simulate different traffic patterns.
- Learn how to view the performance test you create in the Test Builder as a script.
Before you begin
To run a performance test, you will need:
- A Grafana Cloud account.
- Permission to run load tests on an endpoint.
- You have permission to run load tests on the
https://quickpizza.grafana.comwebsite, if you don’t have a website you can test or if you’re just trying out Grafana Cloud k6.
- You have permission to run load tests on the
Create a test with the test builder
The Test Builder is a graphical interface that can help you create a performance test with a GUI, instead of having to write a script. It provides a quick way to prototype tests and learn the basic functionality of the k6 API.
Note
The following test uses 10 VUH. To learn how VUH is calculated, refer to Understand your Performance Testing invoice.
To learn how to make a test, follow these steps:
Log in to your Grafana Cloud instance.
Go to Testing & synthetics > Performance.
Click New test.
If you have more than one project, in the project drop-down menu in the top-right corner of the page, select Default project or the project you want to use.
In the Test Builder card, click Start Building.
In the first field, name the test as
Test demo.At the bottom of the builder, in the toolbar next to GROUP and SLEEP, click REQUEST to add a request.
Configure the request:
- In the Name field, enter
Get homepage. - For the HTTP method, select GET and enter the URL you want to test, or use
https://quickpizza.grafana.com.
Now you have the basics of a test set up, and you can already run it. But k6 doesn’t only make requests, it also models load, or traffic patterns. These load patterns are modeled in test scenarios.
Configure your scenario to model 10 users trying to access the homepage 100 times:
- In the Name field, enter
Under SCENARIO_1, click Options (not the top-level OPTIONS section above SCENARIOS, which is for load zones and thresholds).
In the main panel under GENERAL, open the Executor drop-down menu and select Shared iterations.
Enter the following load pattern:
VUS 10Iterations 100Click Create and Run.
You just started your first load test. The app presents the results in near real time, When it finishes, you can look at granular data for all results output.
Model ramping traffic from multiple geographies
Note
The following test uses 20 VUH. To learn how VUH is calculated, refer to Understand your Performance Testing invoice.
Grafana Cloud k6 provides many options to simulate realistic load. You can modify the same test so that the volume of traffic “ramps up”, which means it increases the number of active virtual users, and comes from multiple load zones, which are locations around the world.
To configure the test for ramping logic, follow these steps:
- Go to Testing & synthetics > Performance, and open the project that contains the test you created in the previous section.
- On the project page, in the upper-right corner of the test card for the test you created, click the menu icon (three dots) and select Configure.
- Under SCENARIO_1, click Options.
- In the main panel under GENERAL, open the Executor drop-down menu and select Ramping VUs.
- In the Ramping VUs section, you can use the default values for Target VUs and Duration, or enter the following load pattern:
Target VUs Duration 20 1m 20 3m30s 0 1m
This load configuration starts with 0 virtual users, ramps up to 20 over a minute, remains at this level for 3 minutes and 30 seconds, then ramps back down to 0.
Now, distribute the geography of the load. Load zones are not under SCENARIO_1; they are in the top OPTIONS section in the left sidebar (above SCENARIOS).
- In the top OPTIONS section, click Load zones.
- Keep Ashburn, US as the first load zone.
- Click Add new load zone and select London, GB. Repeat the process with Sydney, AU.
- Click Save and Run.
As the test runs, a panel shows values for request rate (traffic), response time (latency), and error rate (availabilty).
Next steps
This tutorial provides an overview of building tests using the Test Builder. For more details, refer to Use the Test Builder.
For a next step, you can:
- Learn how to run a cloud test from the CLI.
- Learn how to schedule a test.
Was this page helpful?
Related resources from Grafana Labs


