Production-ready chat interface with React components + Cloudflare Agent backend. Works immediately. Customize everything.
npx agentpacks add chat-ui-starterPowered by Cloudflare Workers AI
Everything you need to ship a chat experience in minutes
Survives disconnects and browser refreshes. No lost tokens.
Conversations saved in Durable Objects. Pick up where you left off.
Runs on Cloudflare Workers. Global, fast, and cost-effective.
Type-safe from hook to worker. Fully customizable.
Clean separation between UI components, state management, and backend
@saas-starter/components
ChatHandler interface
AIChatAgent
Everything is TypeScript. Fully typed, fully customizable.
import { ChatSection, ChatThread } from '@saas-starter/components';
import { useAgentChat } from './hooks/useAgentChat';
export default function ChatPage() {
const handler = useAgentChat({
agent: 'https://chat-ui-agent.YOUR.workers.dev',
});
return (
<ChatSection handler={handler} className="h-screen">
<ChatThread
welcomeHeading="Hello! 👋"
welcomeSubheading="How can I help you today?"
suggestions={[
{ title: "Explain", label: "how this works" },
{ title: "Help me", label: "write some code" },
]}
/>
</ChatSection>
);
}One command, complete project structure
Get the chat-ui-starter pack and deploy your chat interface in minutes.
npx agentpacks add chat-ui-starter