Guide on how to build Kitesurf on your machine, connect Puppeteer via CDP, and understand its limits before deploying it unauthenticated on Cloudflare Workers.
Cloudflare has released Kitesurf on GitHub under the Apache 2.0 license, three months after promising it. It is a browser engine for AI agents, written in Rust and WebAssembly, that speaks the Chrome DevTools Protocol (CDP) and runs on Workers instead of a container with Chromium. Here we review how to spin it up locally and what to expect.
What You Need
You need the cloned repository, the Rust toolchain to compile the core to WebAssembly, Wrangler to serve the engine, and Node.js with puppeteer-core for the client. For a production deployment, a paid Workers plan is also required, because each page runs in its own Dynamic Worker. None of that is needed for local testing.
It is worth reading the official announcement and the Browser Run documentation beforehand, which explain how to choose Kitesurf over managed Chromium.

Steps to Get It Running
- Clone the repository from GitHub and review its README: it is the reference for the exact build commands, which may change as the project evolves.
- First, compile the Rust core to WebAssembly, as indicated in the README.
- Start the local server with Wrangler; a CDP endpoint should be listening on port 8787.
- Install
puppeteer-corein a separate project and connect to the endpoint using the script in the next section. - Run the script and verify that the screenshot is generated. If a specific page fails, it is likely hitting a standards support limit, not an error on your part.
Connecting Puppeteer via CDP
The project claims that an unmodified Puppeteer client works against the local server. This is the minimal example we tested in the guide; it uses a harmless test page:
import puppeteer from "puppeteer-core";
const browser = await puppeteer.connect({
browserWSEndpoint: "ws://127.0.0.1:8787/devtools/browser",
});
try {
const page = await browser.newPage();
await page.goto("https://example.com/");
await page.screenshot({ path: "page.png" });
} finally {
await browser.disconnect();
}Internally, each navigation comes in via Page.navigate, an isolation environment is created for the page script, and when a screencast is requested, each frame is rasterized to JPEG. The components are Blitz (HTML, DOM, layout, and painting), Stylo (CSS), Boa (JavaScript), and Krilla (PDF).
Limits and Precautions
The team itself warns that standards support and rendering fidelity are still work in progress; there is a Web Platform Tests page showing coverage. The stated limits are clear: no video, no WebGL, no anti-bot challenges requiring a real TLS fingerprint, and no long-lived authenticated sessions.
Regarding the question most frequently asked by agent builders—whether it will pass bot-detection systems—there is no answer in the published material. One comment pointed out that Cloudflare opposes unauthorized scraping, so that does not appear to be a goal. Some recommend separating the experiment from production workloads, and on Hacker News someone pointed out the risk of getting locked into the Cloudflare ecosystem.

Original source: infoq.com
Article generated with AI.larebelion



Comments (0)
No comments yet. You can be the first.
Write a comment