Home

Awesome

<h3 align="center">Browser automation and end-to-end web testing for k6</h3> <p align="center">A module for k6 adding browser-level APIs with rough Playwright compatibility.</p> <p align="center"> <a href="https://github.com/grafana/xk6-browser/releases"><img src="https://img.shields.io/github/v/release/grafana/xk6-browser.svg" alt="Github release"></a> <a href="https://github.com/grafana/xk6-browser/actions/workflows/test.yml"><img src="https://github.com/grafana/xk6-browser/actions/workflows/test.yml/badge.svg" alt="Build status"></a> <a href="https://goreportcard.com/report/github.com/grafana/xk6-browser"><img src="https://goreportcard.com/badge/github.com/grafana/xk6-browser" alt="Go Report Card"></a> <br> <a href="https://twitter.com/k6_io"><img src="https://img.shields.io/badge/twitter-@k6_io-55acee.svg" alt="@k6_io on Twitter"></a> </p> <p align="center"> <a href="https://github.com/grafana/k6/releases/latest">Download</a> · <a href="https://grafana.com/docs/k6/latest/javascript-api/k6-browser">Documentation</a> · <a href="https://community.grafana.com/c/grafana-k6/k6-browser/79">Community Forum</a> · <a href="https://github.com/orgs/grafana/projects/443/views/1">Public Roadmap</a> · </p> <br/> <img src="assets/github-hr.svg" height="32" alt="---" /> <br/>

k6-browser is a k6 module that supports browser automation through the Chrome Devtools Protocol (CDP). It adds browser-level APIs to interact with browsers and collect frontend performance metrics as part of your k6 tests.

As of k6 version 0.52.0, k6-browser is now bundled in k6 as a core module and usable without a separate binary or compilation step!

Special acknowledgment to the authors of Playwright and Puppeteer for their trailblazing work in this area.

Goals

Please take a look at our project roadmap for more details.

Get started

Documentation

Get help

Additional resources

To find out more about xk6-browser or browser testing in general, check out the following links.

Note: Since our API is still transitioning, some of the code snippets from the links below might be inaccurate, though the concepts should still be correct. For the latest, please take a look at our up-to-date API documentation.