Cap'n Web: A new RPC system for browsers and web servers
Sep 22, 2025Kenton Varda, Steve Faulkner

Summary
Introduces Cap'n Web, a new RPC system for JavaScript environments (browsers, Workers, Node.js). It implements an object-capability RPC model, supports JSON serialization, and works over HTTP, WebSocket, and postMessage. Key features include bidirectional calling, passing functions/objects by reference, promise pipelining, and capability-based security. It integrates with TypeScript and has a small footprint. The post provides examples of client and Cloudflare Worker server implementations, highlighting its ease of use and expressiveness.