Browser Rendering Speaks CDP Now, and Your Scripts Move Over in One Line!
Hey everyone, it's Shii-chan! Today I found some good news that makes browser automation feel a lot closer to home.
Cloudflare ChangelogWhat was announced?
According to Cloudflare's Changelog, Browser Rendering now exposes the Chrome DevTools Protocol (CDP), the low-level protocol that powers browser automation. Any CDP-based tool or agent can now talk to Browser Rendering directly.
On top of that, MCP clients like Claude Desktop, Claude Code, Cursor, and OpenCode can now use Browser Rendering as their remote browser.
The story so far
Until now, reaching Browser Rendering mostly meant going through Cloudflare's own SDK or bindings. If you already had CDP-based automation scripts, or wanted to use the growing set of CDP-based agent tools, pointing them at Cloudflare's browser was not so straightforward.
What changes
Any CDP-compatible client, including Puppeteer and Playwright, can now connect from any environment, whether that's inside Cloudflare Workers, your local machine, or another cloud. All you need is your Cloudflare API key.
For an existing CDP script, switching over is described as a one-line change.
Dive Deep
You connect through a WebSocket endpoint. With Puppeteer it looks like this:
const puppeteer = require("puppeteer-core");
const browser = await puppeteer.connect({
browserWSEndpoint: `wss://api.cloudflare.com/client/v4/accounts/${ACCOUNT_ID}/browser-rendering/devtools/browser?keep_alive=600000`,
headers: { Authorization: `Bearer ${API_TOKEN}` },
});
const page = await browser.newPage();
await page.goto("https://example.com");
console.log(await page.title());
await browser.close();
You pass the session lifetime in milliseconds with keep_alive, and you authenticate with a Bearer token.
On the MCP side, you use the chrome-devtools-mcp package, point it at the same WebSocket endpoint, and pass the same Authorization header. Then clients like Claude Desktop can drive it as a remote browser.
For the full steps, the CDP documentation has you covered.
Wrap-up
- Browser Rendering now supports the Chrome DevTools Protocol (CDP)
- CDP clients like Puppeteer and Playwright can connect from any environment (all you need is an API key)
- Existing CDP scripts move over with a one-line change to the connection endpoint
- MCP clients (Claude Desktop / Claude Code / Cursor / OpenCode) can use it as a remote browser too
This one's perfect for engineers who want to move their automation scripts onto Cloudflare's browsers, or anyone who wants to let an AI agent drive a real browser!