Cloudflare Kitesurf更新:支持WebMCP与终端渲染
The road to the agentic browser: A Kitesurf update
Agent开发者的利器,WebMCP支持让网页交互从“盲点”变“直调”,效率质变,建议关注其Browser Run集成方案。
In August, we introduced Kitesurf, a browser for the agentic age that runs entirely on Cloudflare Workers. We built it around what agents need from the web, rather than carrying all the features and bloat of a browser designed for humans. If this is the first you’re hearing about it, we highly recommend you read the blog post where we introduced Kitesurf, for all the juicy technical details of how we did it.
8月,我们推出了 Kitesurf,这是一款专为智能体时代打造的浏览器,完全运行在 Cloudflare Workers 之上。我们围绕智能体对 Web 的需求来构建它,而非沿用为人类设计的浏览器所附带的所有功能和冗余代码。如果你是第一次听说它,我们强烈建议你阅读介绍 Kitesurf 的博客文章,了解我们如何实现它的详细技术细节。
Since then, we’ve put Kitesurf through increasingly realistic tasks and used internal and external feedback from customers to make it more capable and more efficient. Here’s what has changed, how you can try it today, and where we’re going next.
此后,我们让 Kitesurf 应对越来越真实的任务,并利用来自客户的内部和外部反馈,使其功能更强大、效率更高。以下是已发生的变更、你今天如何试用它,以及我们接下来的发展方向。
WebMCP support
WebMCP 支持
Websites were not built for agents to use. Browsing today is a messy process of clicking pixels and hoping the right element loads. In a programmatic world this is slow and fragile. WebMCP helps by allowing developers to expose site functionality directly to agents, where they can call functions like searchFlights() instead of simulating clicks.
网站并非为智能体使用而构建。如今的浏览过程杂乱无章,需要点击像素并指望正确的元素加载。在编程世界中,这种方式既缓慢又脆弱。WebMCP 通过允许开发者将站点功能直接暴露给智能体来解决这一问题,智能体可以调用如 searchFlights() 之类的函数,而不是模拟点击操作。
Cloudflare has been supporting WebMCP since its early days; just a few weeks ago we announced that site owners can now turn on WebMCP with one switch, so browser agents can discover and use tools on their sites without changing the site’s code, and Browser Run has been supporting WebMCP when using Chrome beta for some time now.
Cloudflare 自 WebMCP 早期阶段就开始提供支持;就在几周前,我们宣布站点所有者现在只需一键即可启用 WebMCP,这样浏览器智能体无需更改站点代码即可发现并使用其站点上的工具,并且 Browser Run 在使用 Chrome beta 版本时也已支持 WebMCP 一段时间了。
Today we are announcing that Kitesurf now supports WebMCP.
今天我们宣布,Kitesurf 现已支持 WebMCP。
You can test this by going to our public Kitesurf playground, opening Cloudflare Radar, and navigating to WebMCP on the Application tab in the DevTools panel. As you can see, Radar exposes a list of WebMCP tools like navigate-to or set-location which allow clients to interact with the page and explore Radar programmatically.
你可以通过访问我们的公共 Kitesurf 游乐场,打开 Cloudflare Radar,并在 DevTools 面板的 Application 标签页中导航至 WebMCP 来进行测试。正如你所见,Radar 暴露了一系列 WebMCP 工具(如 navigate-to 或 set-location),允许客户端与页面交互并以编程方式探索 Radar。
If you target Kitesurf with your AI Agent:
如果你的 AI 智能体针对 Kitesurf 进行开发:
You can see that the AI model can interact with the exposed WebMCP tools which you can use to complete tasks more reliably.
你可以看到 AI 模型能够与暴露的 WebMCP 工具进行交互,从而更可靠地完成各项任务。
You can read more about how to use WebMCP with Kitesurf and Browser Run here.
你可以在这里阅读更多关于如何在 Kitesurf 和 Browser Run 中使用 WebMCP 的内容。
New APIs, better WPT coverage
新 API,更好的 WPT 覆盖率
Since the initial announcement, we’ve been adding more browser standards so that agents can render more sophisticated pages. The list of the APIs that Kitesurf supports has grown, and now includes:
自首次发布以来,我们一直在添加更多的浏览器标准,以便智能体能够渲染更复杂的页面。Kitesurf 支持的 API 列表不断增长,现在包括:
- WebMCP
- CSS Layout
- CSS Object Model (CSSOM)
- CSS Typed OM
- Custom elements
- WebMCP
- CSS Layout
- CSS Object Model (CSSOM)
- CSS Typed OM
- 自定义元素
We added URL-based module resolution, JSON modules, and import map handling—important for sites that load JavaScript in chunks. Additionally we are using the new Cloudflare Workers’ module registry to support imports from URLs.
我们添加了基于 URL 的模块解析、JSON 模块以及 import map 处理——这对于以分块方式加载 JavaScript 的网站至关重要。此外,我们还利用新的 Cloudflare Workers 模块注册表来支持从 URL 导入模块。
Iframe behavior has improved as well; now they load at the right time, stay better isolated, and display text correctly across more languages and encodings.
Iframe 的行为也得到了改善;现在它们能在正确的时间加载,保持更好的隔离性,并在更多语言和编码中正确显示文本。
As we said at launch, running tests is how we keep the quality of both code and results under control without losing velocity while improving Kitesurf. Web Platform Tests (WPT) is a shared, open-source test suite that checks whether browsers implement web standards consistently.
正如我们在发布时所说,运行测试是我们控制代码和结果质量的方法,同时在不降低速度的情况下改进 Kitesurf。Web Platform Tests (WPT) 是一个共享的开源测试套件,用于检查浏览器是否一致地实现 Web 标准。
We now pass 730,000+ WPT subtests and are growing. That’s 500,000 more subtests than when we launched. Here you can see the evolution over time, up to the latest version since we started the project:
我们现在通过了 730,000+ 个 WPT 子测试,并且还在持续增长。这比发布时多了 500,000 个子测试。在这里你可以看到自项目启动以来的演变过程,直到最新版本:
Efficiency optimized for agents
为智能体优化效率
For an AI agent, efficiency isn’t so much about loading pages fast, but about the latency of the agentic loop. To make Kitesurf truly agentic, we’ve aggressively optimized the browser engine’s internals so that every DOM traversal, timer, and font fetch is as lightweight as possible, ensuring the agent spends its compute cycles on reasoning, not waiting for the browser to catch up.
对于 AI 智能体而言,效率不仅仅关乎页面加载速度,更关乎智能体循环的延迟。为了让 Kitesurf 真正具备智能体能力,我们大幅优化了浏览器引擎的内部结构,使得每次 DOM 遍历、定时器触发和字体获取都尽可能轻量,确保智能体将其计算周期用于推理,而不是等待浏览器追赶进度。
These optimizations include:
这些优化包括:
- Improved JavaScript execution with less work crossing between Boa and the DOM, making the boundary more compatible with real Web frameworks. Common reads such as getAttribute, id, and parentNode can now be answered inside the Wasm DOM instead of making repeated Boa → JavaScript shim → Wasm trips.
- Kitesurf does less repeated work when running timers and loading scripts, and releases memory from objects it no longer needs. It also handles objects and classes more consistently when code moves between its two JavaScript engines, resulting in running busy pages more efficiently.
- Kitesurf now loads fonts when they’re needed, fetches fewer fonts a page won’t use, checks which characters appear on the page before fetching language-specific font files and renders synthetic italics more faithfully.
- 改进了 JavaScript 执行,减少了在 Boa 和 DOM 之间交叉的工作量,使边界更好地兼容真实的 Web 框架。常见的读取操作(如 getAttribute、id 和 parentNode)现在可以在 Wasm DOM 内部直接响应,而无需反复进行 Boa → JavaScript shim → Wasm 的往返调用。
- Kitesurf 在运行定时器和加载脚本时减少了重复工作,并释放不再需要的对象的内存。当代码在其两个 JavaScript 引擎之间移动时,它对对象和类的处理也更加一致,从而更高效地运行繁忙的页面。
- Kitesurf 现在按需加载字体,减少获取页面不会使用的字体数量,在获取特定语言字体文件之前检查页面上出现的字符,并更忠实地渲染合成斜体。
Together, these optimizations help keep Kitesurf efficient for agents. Despite adding support for more web standards—and bringing Kitesurf closer to the capabilities of full-featured browsers like Chrome—its wall-clock time and CPU usage remain roughly in line with our launch benchmarks, and in some cases they have improved.
综上所述,这些优化有助于保持 Kitesurf 对智能体的高效性。尽管增加了对更多 Web 标准的支持——并使 Kitesurf 更接近 Chrome 等全功能浏览器的能力——其墙钟时间和 CPU 使用率仍大致与我们发布时的基准持平,在某些情况下甚至有所改善。
Plays better with Browser Run
与 Browser Run 更好地协同工作
Browser Run is our developer platform product that lets you programmatically control and run headless browser instances. When you use this API, you can select from a list of browser flavors we support, including Kitesurf.
Browser Run 是我们的开发者平台产品,允许你以编程方式控制和运行无头浏览器实例。使用此 API 时,你可以从我们支持的浏览器变体列表中进行选择,其中包括 Kitesurf。
This means that we have to make sure that all of our browsers are supported across the API surface. Starting today, Kitesurf has full Browser Run API coverage. You can use Kitesurf with CDP, Playwright, Puppeteer, or MCP.
这意味着我们必须确保所有浏览器都能在 API 层面得到支持。从今天起,Kitesurf 已全面覆盖 Browser Run API。你可以将 Kitesurf 与 CDP、Playwright、Puppeteer 或 MCP 配合使用。
One of the most popular Browser Run features, Quick Actions, provide simple interfaces for common browser tasks like capturing screenshots, extracting HTML content, generating PDFs, and more. When we launched Kitesurf, you could use Quick Actions from our REST API. Now you can also use them from inside a Worker script using the env.BROWSER.quickAction() binding:
Browser Run 最受欢迎的功能之一是 Quick Actions(快捷操作),它为捕获截图、提取 HTML 内容、生成 PDF 等常见浏览器任务提供了简洁的接口。在推出 Kitesurf 时,你可以通过我们的 REST API 使用 Quick Actions。现在,你也可以在 Worker 脚本中使用 env.BROWSER.quickAction() 绑定来调用它们:
Kitesurf runs in the terminal now
Kitesurf 现已可在终端中运行
As we detailed in the How we built it section of our announcement blog post, Kitesurf separates PageScript, the isolate that handles the page session and runs the page code, from PageRenderer, which is responsible for generating the actual pixels from the computed page objects.
正如我们在公告博客文章的“构建过程”部分所详述的那样,Kitesurf 将 PageScript(处理页面会话并运行页面代码的隔离环境)与 PageRenderer(负责从计算出的页面对象生成实际像素)分离开来。
This not only gives great isolation and flexibility, but it also allows us to decouple and move the rendering logic to outside Kitesurf (to the client, for example, or to another Worker), while keeping the security-critical parts server-side, running in our network.
这不仅提供了出色的隔离性和灵活性,还允许我们将渲染逻辑解耦并移至 Kitesurf 外部(例如客户端或另一个 Worker),同时保持对安全至关重要的部分在服务端运行,位于我们的网络环境中。
If this model sounds familiar, it may be because Cloudflare has another SASE product called Cloudflare Browser Isolation, which runs all untrusted web code at the edge of our global network while it “streams” the rendering data back to the clients.
如果这种模型听起来很熟悉,那可能是因为 Cloudflare 还有另一款名为 Cloudflare Browser Isolation 的 SASE 产品,它会在我们全球网络的边缘运行所有不受信任的网络代码,同时将渲染数据“流式传输”回客户端。
We can do something similar with Kitesurf. To prove it, we moved PageRenderer to our Playground Worker and patched this version so that instead of converting scene data into an image, it outputs to Kitty—a terminal graphics protocol supported by modern terminals like Kitty itself, Ghostty, WezTerm, and others. We even went a step further and added a pure ANSI text mode for environments where Kitty isn't available.
我们可以用 Kitesurf 实现类似的功能。为了证明这一点,我们将 PageRenderer 移到了我们的 Playground Worker 中,并对该版本进行了修补,使其不再将场景数据转换为图像,而是输出到 Kitty——一种由现代终端(如 Kitty 本身、Ghostty、WezTerm 等)支持的终端图形协议。我们甚至更进一步,添加了一种纯 ANSI 文本模式,以便在不可用 Kitty 的环境中也能使用。
The result is that you can now quickly open and render a page using Kitesurf without leaving the comfort of your terminal application. This is super useful not only because you can now browse the modern Web at a glance without context-switching, but you can also use this tool to see how an agent using Kitesurf “sees” a page.
结果是,你现在可以在不离开终端应用程序舒适区的情况下,快速打开并使用 Kitesurf 渲染页面。这非常有用,不仅因为你可以一目了然地浏览现代 Web 而无需切换上下文,还可以利用此工具查看使用 Kitesurf 的代理“看到”的页面是什么样的。
To install the terminal version of Kitesurf, do this:
要安装 Kitesurf 的终端版本,请执行以下操作:
From now on just type this in terminal:
从现在开始,只需在终端中输入以下内容:
Here’s a demo of it working.
以下是其工作演示。
The terminal also sends back scrolling and click events, so you use the keyboard, arrows, or the mouse normally, as if you were in a dedicated browser application window.
终端还会回传滚动和点击事件,因此你可以像在使用专用浏览器应用程序窗口时一样,正常使用键盘、方向键或鼠标。
And here is our Silent Space Marine Doom demo running in Kitesurf inside the terminal:
以下是我们的 Silent Space Marine Doom 演示在终端内通过 Kitesurf 运行的画面:
Where we go from here
接下来的发展方向
We continue to iterate rapidly on the road to the best agentic browser for our customers and developers. Expect ever-better performance benchmarks and for the list of supported Web standards and WPT test coverage to continue to rise quickly. In fact, we’ve decided to publish the results here and here, in the open, so that you track them as we move forward, in real time.
我们将持续快速迭代,致力于为客户和开发者打造最佳的智能体浏览器。预期性能基准测试将不断提升,支持的 Web 标准列表以及 WPT(Web Platform Tests)测试覆盖率也将迅速增长。事实上,我们决定在此处和此处公开公布这些结果,以便您在后续进展中实时跟踪。
更进一步:量化金融体系
看懂新闻只是起点——沿量化金融路径,把它变成能交付的工程能力