The primitive for
stateful workloads.
One Actor per agent, per session, per user. The same primitive powers realtime apps, multiplayer, and collaborative state.
One primitive, every stateful workload.
The same Actor that holds an agent's memory holds a game lobby, a shared document, or a running workflow.
AI agents
One Actor per agent. Persistent memory, tool execution, and long-running context that survives restarts — in your existing Node.js or Bun backend.
Read the docsRealtime & multiplayer
WebSockets and event broadcast built in. One Actor per room, match, or channel keeps every client in sync without a separate realtime service.
Read the docsCollaborative state
One Actor per document or workspace. State lives next to compute, so concurrent edits stay consistent without cache-invalidation gymnastics.
Read the docsDurable workflows
Queues, schedules, and timers on the same primitive. Multi-step operations pick up where they left off, even across sleeps and deploys.
Read the docsA lightweight primitive with powerful capabilities.
One Actor per agent, per session, per user — state, storage, and networking included.
Co-located with compute for instant reads and writes. Persist with SQLite or BYO database.
Long-lived when active, hibernates when idle.
Sleeps at near-zero cost when idle, fans out when traffic spikes.
Deploy close to your users or in specific legal jurisdictions without complexity.
Real-time bidirectional streaming built in.
Multi-step operations with automatic retries.
Durable message queues for reliable async processing.
Timers and cron jobs within your actor.
Actors in action.
One primitive that adapts to agents, workflows, collaboration, and more.
const agent = actor({
// In-memory, persisted state for the actor
state: { messages: [] },
// Long-running actor process
run: async (c) => {
// Process incoming messages from the queue
for await (const msg of c.queue.iter()) {
c.state.messages.push({ role: "user", content: msg.body.text });
const response = streamText({ model: openai("gpt-5"), messages: c.state.messages });
// Stream realtime events to all connected clients
for await (const delta of response.textStream) {
c.broadcast("token", delta);
}
c.state.messages.push({ role: "assistant", content: await response.text });
}
},
});const agent = client.agent.getOrCreate("agent-123").connect();
agent.on("token", delta => process.stdout.write(delta));
await agent.queue.send("hello!");Each agent runs as its own actor with persistent context, memory, and the ability to schedule tool calls.
How Actors Compare
Rivet Actors vs. traditional infrastructure.
Actors scale to zero with no idle infrastructure.
Methodology — figures are directional, measured on commodity AWS infrastructure. Hover each entry for the measurement setup.


Built-In Observability
Debugging and monitoring for actors and agents, from local development to production at scale.
SQLite Viewer
Browse and query SQLite databases in real-time across actors and agent sessions
Workflow State
Inspect workflow progress, steps, and retries as they execute
Event Monitoring
Track every state change, action, and agent event as it happens in real-time
REPL
Debug actors and agent sessions by calling actions, subscribing to events, and interacting directly with your code
Frequently asked questions
Infrastructure for
the agentic era.
Build with agents, build for agents, and run it where your data lives.
