Skip to content

Playwright import

Playwright logo

Playwright is an automation framework created by Microsoft. It allows testers to write automated tests using a single API that works across multiple browsers, including Chrome, Firefox, and Microsoft Edge.


Using real browsers generally makes the Virtual Users creation process faster since no correlations will be required. But on the other hand real browsers cannot generate the same amount of Virtual Users per load generator. That's why we limit Playwright users to 5 Virtual users per load generator compared to 1000 for JMeter Virtual Users.


Before you import a Playwright Virtual user inside OctoPerf, it is recommended to use a local installation of Playwright to capture a user journey.

The official playwright installation guide explains all there is to know in order to get started. Simply make sure to have Node.js installed in order to follow their instructions.


For a step by step guide on how to install and configure playwright follow our introduction blog post here.

Recording with Playwright

Once Playwright is installed on your computer, you can use the build-in recorder to create your first script. We are going to record on our public demo application:

npx playwright codegen

After a few seconds a new window opens where we can navigate inside the Petstore:


And at the same time, the corresponding playwright script is generated:


This .ts script is what you can upload in OctoPerf next.


For a step by step guide on how to record with playwright follow our recording guide here.

Import your recording

Select the .ts script file you want to upload:


You can also add a custom Package.json file, otherwise the default one will be used.


If you do not provide any file, we will create a new Playwright script using a template testing our demo application.