When your agent needs a face and a pause button
A React SDK that lets AI agents render UI mid-thought and ask humans for help before continuing.

What it does
CopilotKit is a TypeScript SDK for wiring AI agents into frontend applications. It provides React hooks and components for chat interfaces, plus a synchronized state layer so agents and UI components can read and write shared data in real time. The useAgent hook exposes agent state directly to components for programmatic control.
The interesting bit
The “Generative UI” pattern: agents can dynamically render React components at runtime based on user intent and agent state, not just return text. The project also stewards the AG-UI Protocol, an open standard for agent-user interactions adopted by Google, LangChain, AWS, Microsoft, and others — which means the wiring isn’t proprietary glue.
Key highlights
- Human-in-the-loop workflows — agents pause execution to request user input, confirmation, or edits before continuing
- Backend tool rendering — server-side agent tools return UI components that render directly in the client
- Three generative UI modes — static (AG-UI Protocol), declarative (A2UI), and open-ended (MCP Apps & Open JSON)
- First-party integrations with LangGraph, CrewAI, and other agent frameworks
- Claude Code plugin — the monorepo doubles as a plugin with 9 skills for lifecycle journeys
Caveats
- The README leans heavily on marketing language (“best-in-class,” “1 minute”) without substantiation
- Actual protocol specification details live in a separate repository; this repo is the SDK implementation
- Multi-framework support is claimed but React appears to be the first-class citizen
Verdict
Worth evaluating if you’re building agentic features in React and need structured human intervention points. Skip if you’re committed to a non-React stack or want a lightweight, protocol-agnostic solution — the surface area here is broad.
Frequently asked
- What is CopilotKit/CopilotKit?
- A React SDK that lets AI agents render UI mid-thought and ask humans for help before continuing.
- Is CopilotKit open source?
- Yes — CopilotKit/CopilotKit is open source, released under the MIT license.
- What language is CopilotKit written in?
- CopilotKit/CopilotKit is primarily written in TypeScript.
- How popular is CopilotKit?
- CopilotKit/CopilotKit has 36.6k stars on GitHub and is currently accelerating.
- Where can I find CopilotKit?
- CopilotKit/CopilotKit is on GitHub at https://github.com/CopilotKit/CopilotKit.