Convert a JMeter script to k6
Grafana’s own jmeter-to-k6 converter is archived, and every other option is a command-line tool you have to install first. This one runs inside your browser tab: drop in a .jmx, get a k6 script back. Your test plan is never uploaded — the page has no way to send it anywhere.
Convert a JMeter script nowHow to do it
-
Save the test plan as a .jmx
In JMeter, File → Save Test Plan As. A .jmx is XML, so the file you already have is the file the converter reads — no export step.
-
Drop it on the converter
Open the converter with JMeter → k6 already selected, then drag the .jmx anywhere onto the page or choose it with the file picker. Click Convert. It takes a few milliseconds and issues no network requests.
-
Read the warnings before the script
Anything that could not be translated faithfully — a JSR223 sampler, a plugin thread group — is listed under the result. That list is the manual work; the script itself is a starting point that runs.
-
Run it once with one user
k6 run --vus 1 --iterations 1 script.js. Compare the request count with the original plan and look for a 401 on the second request in — that is a session value replayed from the recording, and it needs extracting before this is a load test.
What it handles
- HTTP requests, with headers, query parameters and bodies
- Assertions — response code, text and duration checks become k6 `check()` calls
- Extractors — regex, JSON and boundary extractors become variable assignments
- CSV Data Set Config becomes a k6 SharedArray with the same fields
- Thread groups, ramp-up and duration become k6 stages
- Think times, including uniform and Gaussian random timers
- Transaction controllers become k6 groups
What it will not do
- The free browser version stops at 25 HTTP requests — enough for one user journey, not a whole suite.
- JSR223 and BeanShell scripting cannot be translated. Anything with Groovy in it is flagged, not guessed at.
- Correlation is reported, not applied: it tells you which recorded values will be stale on the next run, and you decide what to do about them.
- Plugin-specific samplers outside core JMeter are listed as unconverted rather than silently dropped.
Questions
Is my test plan uploaded anywhere?
No. The converter is compiled to WebAssembly and runs inside the tab. That origin is served with a Content-Security-Policy of `default-src ’none’` and `connect-src ’self’`, so the page is not permitted to make a network call at all — it is enforced by the browser, not promised by us.
What happened to Grafana’s jmeter-to-k6?
It has been archived. The repository now lives in Grafana’s cold-storage organisation, read-only, with its last change in February 2022. It was also a Node command-line tool, so even the archived version needs npm or Docker before you can try it. k6 Studio, Grafana’s current tool, records a browser session or imports a HAR file; it does not read a JMeter test plan.
Will the output actually run?
The generated script is valid k6 and passes perf-lint with no errors. Whether it passes against your system depends on correlation — session tokens and generated identifiers recorded in the original will need extracting, and the converter tells you which ones.
What if my suite is bigger than the free cap?
Beyond 25 requests you have two options: Perf Script Studio, a £99 one-time binary that converts everything and runs in CI, or a fixed-price migration where the work is done for you and returned with a written report.
Try it on your own file
No account, no upload, no email address. It runs in the tab and stops when you close it.
Convert a JMeter script now