---
title: Puppeteer Recorder with Chrome DevTools | TestingBot
description: Record Puppeteer scripts with Chrome DevTools' built-in Recorder, then
  run them on TestingBot's cloud browser grid. Export as Puppeteer code and point
  at our WebSocket endpoint, zero rewriting required.
source_url:
  html: https://testingbot.com/support/web-automate/puppeteer/recorder
  md: https://testingbot.com/support/web-automate/puppeteer/recorder.md
---

# Introduction

Since Chrome 89, Chrome DevTools has an option to record/generate Puppeteer scripts by recording the actions that you do in your Chrome browser.

At the time of writing this documentation, this feature is still set as a Chrome DevTools experiment.   
 To enable the experiment, check the `Recorder` checkbox under `Settings` \> `Experiments` in your Chrome Devtools.

## Example

To start recording, go to the **Sources** panel in Chrome DevTools. Then select the **Recording** tab on the left pane:

 ![puppeteer recording](https://testingbot.com/assets/support/puppeteer/tab-3155a96aa174390eae3f10d0f48e0b3c27ea509afbdfecf105257c6ca276593d.webp)

You can now add a new recording and give it a name:

Finally, you're ready to start recording. Click on the **Record** button at the bottom to start recording your interactions. Click on the Record button again to stop the recording.

Chrome DevTools will generate a Puppeteer script. You can easily modify this script to have it connect to the TestingBot browser grid:

 ![puppeteer recording](https://testingbot.com/assets/support/puppeteer/record-5ac6d036099e2cd5ec5533006cc3eb57739bfc625fa5082dc4b95a02bc8344f3.webp)

Now you can make a simple change, to have your puppeteer script point to our browser grid:

### Before

```javascript
const browser = await puppeteer.launch()
```

### After

```javascript
const capabilities = {
    'tb:options': {
        key: process.env.TB_KEY,
        secret: process.env.TB_SECRET
    },
    browserName: 'chrome',
    browserVersion: 'latest'
}
const browser = await puppeteer.connect({
  browserWSEndpoint: `wss://cloud.testingbot.com/puppeteer?capabilities=${encodeURIComponent(JSON.stringify(capabilities))}`
})
```

### Looking for more help?

Have questions or need more information? Reach out via email or Slack.

[Email us](https://testingbot.com/contact/new) [Join our Slack](https://join.slack.com/t/testingb0t/shared_invite/zt-3bcw9xch-jk19~6XPs_xBrsAgAedkCw)
