Skip to main content
Kernel browsers were designed to be lightweight, fast, and efficient for cloud-based browser automations at scale. They can be used as part of the Kernel app platform or connected to from another service with the Chrome DevTools Protocol.

1. Create a Kernel browser

First, install the Kernel SDK:
  • Typescript/Javascript: npm install @onkernel/sdk
  • Python: pip install kernel
Use our SDK to create a browser:

2. Connect over CDP

Then, you can connect to the browser with any Chrome DevTools Protocol framework, such as Playwright or Puppeteer. You can also use our Computer Controls API to control the browser’s mouse and keyboard without using a CDP connection. This is useful for vision-based LLM loops like Claude Computer Use.

3. Tear it down

When you’re finished with the browser, you can delete it:
Browsers automatically delete after a timeout (default 60 seconds) if they don’t receive a CDP or live view connection. You can configure this timeout when creating the browser.

Full example

Once you’ve connected to the Kernel browser, you can do anything with it.
Kernel browsers launch with a default context and page. Make sure to access the existing context and page (contexts()[0] and pages()[0]), rather than trying to create a new one.