agents

Build and deploy AI Agents on Cloudflare

What is agents?

Build and deploy AI Agents on Cloudflare

Overview of agents

What it is

Cloudflare Agents is an open-source framework for building and deploying AI agents on Cloudflare's edge network. Each agent runs as a persistent, stateful Durable Object that can hibernate when idle and wake on demand, enabling millions of agents to run cost-effectively. The framework provides built-in support for real-time communication, scheduling, AI model calls, MCP, workflows, and more.

Key features

  • Persistent state that syncs to all connected clients and survives restarts
  • Callable methods via the @callable() decorator for type-safe RPC
  • Sub-agents (facets) for parent/child composition with nested routing
  • Scheduling with one-time, recurring, and cron-based tasks
  • WebSockets for real-time bidirectional communication with lifecycle hooks
  • AI chat with message persistence, resumable streaming, and tool execution
  • MCP support: act as MCP servers or connect as MCP clients (HTTP, SSE, RPC, elicitation)

Use cases

Cloudflare Agents is suitable for building per-user or per-session AI assistants, real-time collaborative applications, game rooms, voice agents, email agents, workflow systems with human-in-the-loop approval, and browser-based agents. The framework includes 30+ example demos covering chat, MCP, code mode, voice, workflows, auth, payments, and games.

Getting started

shnpm create cloudflare@latest -- --template cloudflare/agents-starterOr add to an existing project:shnpm install agents

License and pricing

This project is open-source under the MIT license. Pricing is not stated in the provided materials.

Based on the project's public README and repository metadata.

Add this badge to your README

Featured on YunoDB Badge styles & help

Maintain this project? Show that it is featured on YunoDB.

Markdown[![Featured on YunoDB](https://yunodb.com/badge/cloudflareagents.svg)](https://yunodb.com/tools/cloudflareagents?utm_source=github&utm_medium=badge)
HTML<a href="https://yunodb.com/tools/cloudflareagents?utm_source=github&utm_medium=badge"><img src="https://yunodb.com/badge/cloudflareagents.svg" alt="Featured on YunoDB" height="20"></a>