# OpenUI > Full-stack, renderer-agnostic Generative UI built on OpenUI Lang, a streaming-first language with official React support, community integrations, and up to 67% fewer tokens than JSON. ## Project - [OpenUI website](https://www.openui.com/): Canonical OpenUI website. - [OpenUI source repository](https://github.com/thesysdev/openui): Source code and releases. ## Documentation - [How OpenUI works](https://www.openui.com/docs/architecture.mdx): OpenUI documentation for How OpenUI works. Canonical source: https://www.openui.com/docs/architecture - [Deploy your app](https://www.openui.com/docs/deploy.mdx): Deploy an OpenUI app to Vercel with the OpenUI CLI. Canonical source: https://www.openui.com/docs/deploy - [Getting Started](https://www.openui.com/docs/getting-started.mdx): Create a new OpenUI application or add OpenUI to an existing agent. Canonical source: https://www.openui.com/docs/getting-started - [Introduction](https://www.openui.com/docs.mdx): OpenUI documentation for Introduction. Canonical source: https://www.openui.com/docs - [assistant-ui](https://www.openui.com/docs/build-agents/assistant-ui.mdx): Render OpenUI Lang in an existing assistant-ui chat. Canonical source: https://www.openui.com/docs/build-agents/assistant-ui - [Backend setup](https://www.openui.com/docs/build-agents/backend-setup.mdx): Configure an existing agent backend to generate reliable OpenUI Lang. Canonical source: https://www.openui.com/docs/build-agents/backend-setup - [CopilotKit](https://www.openui.com/docs/build-agents/copilotkit.mdx): Render OpenUI Lang in an existing CopilotKit chat. Canonical source: https://www.openui.com/docs/build-agents/copilotkit - [Custom Chat UI](https://www.openui.com/docs/build-agents/custom-chat-ui.mdx): Render OpenUI Lang in an existing chat interface. Canonical source: https://www.openui.com/docs/build-agents/custom-chat-ui - [Overview](https://www.openui.com/docs/build-agents.mdx): Add OpenUI Lang to an existing agent framework or chat UI. Canonical source: https://www.openui.com/docs/build-agents - [@openuidev/assistant-ui](https://www.openui.com/docs/api-reference/assistant-ui.mdx): API reference for rendering OpenUI Lang tool calls in assistant-ui applications. Canonical source: https://www.openui.com/docs/api-reference/assistant-ui - [@openuidev/cli](https://www.openui.com/docs/api-reference/cli.mdx): API reference for the OpenUI CLI to scaffold apps, mint Gateway API keys, and generate system prompts or library specs, and deploy projects. Canonical source: https://www.openui.com/docs/api-reference/cli - [@openuidev/devtools](https://www.openui.com/docs/api-reference/devtools.mdx): API reference for the development-only devtools widget. Canonical source: https://www.openui.com/docs/api-reference/devtools - [OpenUI SDK](https://www.openui.com/docs/api-reference.mdx): Package guide for the full OpenUI SDK surface, including framework-agnostic, React, Vue, Svelte, email, browser-bundle, and CLI entrypoints. Canonical source: https://www.openui.com/docs/api-reference - [@openuidev/langchain](https://www.openui.com/docs/api-reference/langchain.mdx): API reference for streaming LangChain and LangGraph agents to OpenUI over AG-UI. Canonical source: https://www.openui.com/docs/api-reference/langchain - [@openuidev/react-email](https://www.openui.com/docs/api-reference/react-email.mdx): API reference for the pre-built email templates library and prompt options. Canonical source: https://www.openui.com/docs/api-reference/react-email - [@openuidev/react-headless](https://www.openui.com/docs/api-reference/react-headless.mdx): API reference for chat state, hooks, streaming adapters, and message types. Canonical source: https://www.openui.com/docs/api-reference/react-headless - [@openuidev/react-lang](https://www.openui.com/docs/api-reference/react-lang.mdx): API reference for the OpenUI Lang runtime, library, parser, and renderer. Canonical source: https://www.openui.com/docs/api-reference/react-lang - [@openuidev/react-ui](https://www.openui.com/docs/api-reference/react-ui.mdx): API reference for the AgentInterface chat surface and default component library exports. Canonical source: https://www.openui.com/docs/api-reference/react-ui - [Authentication](https://www.openui.com/docs/gateway/authentication.mdx): Authenticate server-side generation and scoped browser access to Gateway conversations. Canonical source: https://www.openui.com/docs/gateway/authentication - [BYOK](https://www.openui.com/docs/gateway/byok.mdx): Route Gateway requests through your own OpenAI, Anthropic, or Google provider key. Canonical source: https://www.openui.com/docs/gateway/byok - [Generative UI Quickstart](https://www.openui.com/docs/gateway/generate-openui-lang.mdx): Generate validated OpenUI Lang through OpenUI Gateway. Canonical source: https://www.openui.com/docs/gateway/generate-openui-lang - [Introduction](https://www.openui.com/docs/gateway.mdx): Access models across providers with automatic failover and correction for generated interfaces. Canonical source: https://www.openui.com/docs/gateway - [Migrate to OpenUI Gateway](https://www.openui.com/docs/gateway/migrate-to-openui-gateway.mdx): Move an existing OpenAI-compatible application to Gateway with minimal changes. Canonical source: https://www.openui.com/docs/gateway/migrate-to-openui-gateway - [Models](https://www.openui.com/docs/gateway/models.mdx): Find and use model identifiers supported by OpenUI Gateway. Canonical source: https://www.openui.com/docs/gateway/models - [Pricing](https://www.openui.com/docs/gateway/pricing-credits.mdx): Understand Gateway plans, API call charges, model usage, and BYOK. Canonical source: https://www.openui.com/docs/gateway/pricing-credits - [Prompt Caching](https://www.openui.com/docs/gateway/prompt-caching.mdx): Reuse stable prompt prefixes to reduce model costs and response latency. Canonical source: https://www.openui.com/docs/gateway/prompt-caching - [Reliability](https://www.openui.com/docs/gateway/reliability.mdx): Keep model requests working when providers are unavailable or models return invalid OpenUI Lang. Canonical source: https://www.openui.com/docs/gateway/reliability - [Coding Agent Setup](https://www.openui.com/docs/mcp.mdx): Connect OpenUI documentation to your AI coding tools via MCP, agent skills, or LLM-friendly doc formats. Canonical source: https://www.openui.com/docs/mcp - [Dashboard](https://www.openui.com/docs/observability/dashboard.mdx): Use the hosted dashboard to find recurring OpenUI errors and inspect affected generations. Canonical source: https://www.openui.com/docs/observability/dashboard - [Overview](https://www.openui.com/docs/observability.mdx): Find and understand OpenUI generation and rendering errors across production traffic. Canonical source: https://www.openui.com/docs/observability - [Installation](https://www.openui.com/docs/observability/installation.mdx): Connect an OpenUI application to hosted Observability with the official production SDK. Canonical source: https://www.openui.com/docs/observability/installation - [Optimizing with Observability](https://www.openui.com/docs/observability/optimizing.mdx): Turn recurring runtime errors into focused improvements to components, prompts, and model selection. Canonical source: https://www.openui.com/docs/observability/optimizing - [Architecture](https://www.openui.com/docs/openui-lang/architecture.mdx): Build dashboards, CRUD interfaces, and monitoring tools. The LLM generates the UI once, then your app runs independently. Canonical source: https://www.openui.com/docs/openui-lang/architecture - [Benchmarks](https://www.openui.com/docs/openui-lang/benchmarks.mdx): Token efficiency and latency comparison of OpenUI Lang vs YAML, Vercel JSON-Render, and Thesys C1 JSON. Canonical source: https://www.openui.com/docs/openui-lang/benchmarks - [Built-in Functions](https://www.openui.com/docs/openui-lang/builtins.mdx): Transform, filter, and aggregate data with @-prefixed built-in functions. Canonical source: https://www.openui.com/docs/openui-lang/builtins - [OpenUI vs others](https://www.openui.com/docs/openui-lang/comparison.mdx): OpenUI vs json-render (Vercel), A2UI (Google), and CopilotKit OpenGenerativeUI. Canonical source: https://www.openui.com/docs/openui-lang/comparison - [Defining Components](https://www.openui.com/docs/openui-lang/defining-components.mdx): Define OpenUI components with Zod and React renderers. Canonical source: https://www.openui.com/docs/openui-lang/defining-components - [Developer Tools](https://www.openui.com/docs/openui-lang/developer-tools.mdx): Use Inspect and Debug in development to watch streams, catch errors, and try OpenUI Lang against your own components. Canonical source: https://www.openui.com/docs/openui-lang/developer-tools - [Evolution Guide](https://www.openui.com/docs/openui-lang/evolution-guide.mdx): How OpenUI Lang evolved from static UI generation to interactive, data-driven apps. Canonical source: https://www.openui.com/docs/openui-lang/evolution-guide - [Incremental Editing](https://www.openui.com/docs/openui-lang/incremental-editing.mdx): Edit existing UIs efficiently - the LLM patches only what changed, the parser merges it. Canonical source: https://www.openui.com/docs/openui-lang/incremental-editing - [Introduction](https://www.openui.com/docs/openui-lang.mdx): OpenUI documentation for Introduction. Canonical source: https://www.openui.com/docs/openui-lang - [Interactivity](https://www.openui.com/docs/openui-lang/interactivity.mdx): Handle actions, forms, and state in OpenUI components. Canonical source: https://www.openui.com/docs/openui-lang/interactivity - [Overview](https://www.openui.com/docs/openui-lang/overview.mdx): Understand the language, prompt, parser, and renderer that turn model output into application UI. Canonical source: https://www.openui.com/docs/openui-lang/overview - [Patterns](https://www.openui.com/docs/openui-lang/patterns.mdx): Complete examples showing how Query, $variables, @builtins, and actions compose together. Canonical source: https://www.openui.com/docs/openui-lang/patterns - [Prompts](https://www.openui.com/docs/openui-lang/prompts.mdx): Legacy prompt page kept for compatibility; use System Prompts. Canonical source: https://www.openui.com/docs/openui-lang/prompts - [Queries & Mutations](https://www.openui.com/docs/openui-lang/queries-mutations.mdx): Fetch and write data from your tools - the LLM generates the wiring, the runtime executes it. Canonical source: https://www.openui.com/docs/openui-lang/queries-mutations - [Quick Start](https://www.openui.com/docs/openui-lang/quickstart.mdx): Build a Recipe Remix agent with OpenUI Gateway in about 10 minutes. Canonical source: https://www.openui.com/docs/openui-lang/quickstart - [Reactive State](https://www.openui.com/docs/openui-lang/reactive-state.mdx): Make your UI interactive with $variables that update automatically. Canonical source: https://www.openui.com/docs/openui-lang/reactive-state - [Reliability](https://www.openui.com/docs/openui-lang/reliability.mdx): Build reliable LLM-generated interfaces by measuring, reducing, and correcting generation errors. Canonical source: https://www.openui.com/docs/openui-lang/reliability - [The Renderer](https://www.openui.com/docs/openui-lang/renderer.mdx): Parse and render OpenUI Lang streams in React. Canonical source: https://www.openui.com/docs/openui-lang/renderer - [v0.1](https://www.openui.com/docs/openui-lang/specification-v01.mdx): The original OpenUI Lang specification for declarative UI generation in chat responses. Canonical source: https://www.openui.com/docs/openui-lang/specification-v01 - [v0.5 (Latest)](https://www.openui.com/docs/openui-lang/specification-v05.mdx): Full language specification for OpenUI Lang v0.5 - reactive state, queries, mutations, and built-in functions. Canonical source: https://www.openui.com/docs/openui-lang/specification-v05 - [OpenUI Lang Syntax](https://www.openui.com/docs/openui-lang/syntax.mdx): Expression grammar and common component signatures. Canonical source: https://www.openui.com/docs/openui-lang/syntax - [System Prompts](https://www.openui.com/docs/openui-lang/system-prompts.mdx): Generate and customize prompt instructions from your OpenUI library. Canonical source: https://www.openui.com/docs/openui-lang/system-prompts - [Telemetry](https://www.openui.com/docs/openui-lang/telemetry.mdx): What OpenUI Lang collects, why it is collected, and how to control installation and runtime telemetry. Canonical source: https://www.openui.com/docs/openui-lang/telemetry - [Troubleshooting](https://www.openui.com/docs/openui-lang/troubleshooting.mdx): Common issues and fixes when working with OpenUI Lang and the Renderer. Canonical source: https://www.openui.com/docs/openui-lang/troubleshooting - [LangGraph Platform](https://www.openui.com/docs/agent/agent-runtimes/langgraph-platform.mdx): Connect Agent Interface to a LangGraph Platform agent through @openuidev/langchain. Canonical source: https://www.openui.com/docs/agent/agent-runtimes/langgraph-platform - [Pi Agent Harness](https://www.openui.com/docs/agent/agent-runtimes/pi.mdx): Connect Agent Interface to the pi coding agent over an OpenAI-compatible stream. Canonical source: https://www.openui.com/docs/agent/agent-runtimes/pi - [Vercel AI SDK](https://www.openui.com/docs/agent/agent-runtimes/vercel-ai-sdk.mdx): Connect Agent Interface to a Vercel AI SDK streamText backend. Canonical source: https://www.openui.com/docs/agent/agent-runtimes/vercel-ai-sdk - [Vercel Eve](https://www.openui.com/docs/agent/agent-runtimes/vercel-eve.mdx): Connect Agent Interface to Vercel Eve's resumable agent sessions. Canonical source: https://www.openui.com/docs/agent/agent-runtimes/vercel-eve - [Artifacts](https://www.openui.com/docs/agent/core-concepts/artifacts.mdx): Durable, first-class conversation outputs like slides, reports, and apps that the user can open and return to. Canonical source: https://www.openui.com/docs/agent/core-concepts/artifacts - [Conversations](https://www.openui.com/docs/agent/core-concepts/conversations.mdx): How to persist conversations and make them accessible to Agent Interface. Canonical source: https://www.openui.com/docs/agent/core-concepts/conversations - [Generative UI](https://www.openui.com/docs/agent/core-concepts/generative-ui.mdx): Render streamed OpenUI Lang as interactive application components inside a conversation. Canonical source: https://www.openui.com/docs/agent/core-concepts/generative-ui - [Tools](https://www.openui.com/docs/agent/core-concepts/tools.mdx): Let the agent call functions to fetch data and take actions. Canonical source: https://www.openui.com/docs/agent/core-concepts/tools - [Message rendering](https://www.openui.com/docs/agent/customize/message-rendering.mdx): Replace how user and assistant messages render with your own React components, the escape hatch beyond Generative UI. Canonical source: https://www.openui.com/docs/agent/customize/message-rendering - [Sidebar](https://www.openui.com/docs/agent/customize/sidebar.mdx): Add your own nav items to the left sidebar, or replace it entirely through the Sidebar slot. Canonical source: https://www.openui.com/docs/agent/customize/sidebar - [Welcome & starters](https://www.openui.com/docs/agent/customize/welcome-and-starters.mdx): Customize the empty-state welcome screen and the conversation starters that prime a new thread. Canonical source: https://www.openui.com/docs/agent/customize/welcome-and-starters - [Introduction](https://www.openui.com/docs/agent/getting-started/introduction.mdx): A complete React SDK for building streaming agent interfaces with OpenUI Lang. Canonical source: https://www.openui.com/docs/agent/getting-started/introduction - [Quickstart](https://www.openui.com/docs/agent/getting-started/quickstart.mdx): Scaffold a streaming Agent Interface application connected to your model provider. Canonical source: https://www.openui.com/docs/agent/getting-started/quickstart - [Custom artifacts](https://www.openui.com/docs/agent/guides/custom-artifacts.mdx): Add a custom artifact type: produce the data, write a renderer, and register it. Canonical source: https://www.openui.com/docs/agent/guides/custom-artifacts - [Open-ended HTML](https://www.openui.com/docs/agent/guides/open-ended-html.mdx): Generate self-contained HTML experiences and render them in an AgentInterface detailed view. Canonical source: https://www.openui.com/docs/agent/guides/open-ended-html - [Adapters & formats](https://www.openui.com/docs/agent/reference/adapters-and-formats.mdx): Complete reference for AgentInterface's backend channels — the ChatLLM/ChatStorage/ThreadStorage/ArtifactStorage interfaces, the fetchLLM and restStorage factories, the Thread type, the bundled stream adapters, and the message formats. Canonical source: https://www.openui.com/docs/agent/reference/adapters-and-formats - [ props](https://www.openui.com/docs/agent/reference/agentinterface-props.mdx): Complete prop reference for AgentInterfaceProps — adapters, rendering, theme, branding, starters, routing, and children. Canonical source: https://www.openui.com/docs/agent/reference/agentinterface-props - [Components](https://www.openui.com/docs/agent/reference/components.mdx): Reference for the slots and primitive statics on AgentInterface — Sidebar, ThreadHeader, Welcome, Composer, Workspace, SidebarItem, Route, and the rest. Canonical source: https://www.openui.com/docs/agent/reference/components - [defineArtifactRenderer](https://www.openui.com/docs/agent/reference/define-artifact-renderer.mdx): Full reference for the artifact-renderer config — type, toolName, the parser contract, preview/actual, controls, and registry matching. Canonical source: https://www.openui.com/docs/agent/reference/define-artifact-renderer - [Hooks](https://www.openui.com/docs/agent/reference/hooks.mdx): Reference for every AgentInterface hook — navigation, artifact storage and registry, threads and messages, and the detailed-view system. Canonical source: https://www.openui.com/docs/agent/reference/hooks - [Connect a backend](https://www.openui.com/docs/agent/reference/self-hosting.mdx): Connect your LLM with a streaming route and persist threads and artifacts with your own storage. Canonical source: https://www.openui.com/docs/agent/reference/self-hosting - [Autofix API](https://www.openui.com/docs/gateway/api/autofix.mdx): Fix invalid OpenUI Lang from any model with one API call. Canonical source: https://www.openui.com/docs/gateway/api/autofix - [Chat Completions](https://www.openui.com/docs/gateway/api/chat-completions.mdx): OpenUI documentation for Chat Completions. Canonical source: https://www.openui.com/docs/gateway/api/chat-completions - [Conversations API](https://www.openui.com/docs/gateway/api/conversations.mdx): Create persistent Gateway conversations and use them with the Responses API. Canonical source: https://www.openui.com/docs/gateway/api/conversations - [Hosted Tools](https://www.openui.com/docs/gateway/api/responses/hosted-tools.mdx): Enable Gateway-hosted search and MCP tools in Responses API requests. Canonical source: https://www.openui.com/docs/gateway/api/responses/hosted-tools - [Responses API](https://www.openui.com/docs/gateway/api/responses.mdx): Generate corrected OpenUI Lang with persistent conversations and hosted tools. Canonical source: https://www.openui.com/docs/gateway/api/responses - [Shadcn Chat](https://www.openui.com/docs/openui-lang/examples/design-systems/shadcn.mdx): An example of connecting OpenUI Lang to a custom component library, using shadcn/ui as the design system. Canonical source: https://www.openui.com/docs/openui-lang/examples/design-systems/shadcn - [React Email](https://www.openui.com/docs/openui-lang/examples/miscellaneous/react-email.mdx): An AI-powered email generator that uses OpenUI Lang to render 44 React Email components from natural language descriptions. Canonical source: https://www.openui.com/docs/openui-lang/examples/miscellaneous/react-email ## Benchmarks - [Generative UI Benchmark](https://www.openui.com/benchmarks): Visual benchmark page with server-rendered summaries and semantic data tables. - [OpenUI language and model benchmark](https://www.openui.com/benchmarks/language): Focused, canonical comparison of structural validity and cost across 30 models generating OpenUI. - [Language/model benchmark agent document](https://www.openui.com/benchmarks/language/agent.md): Plain Markdown with all model-board results and interpretation notes. - [Language/model benchmark JSON](https://www.openui.com/benchmarks/language/data.json): Focused machine-readable model-board dataset. - [Generative UI framework benchmark](https://www.openui.com/benchmarks/framework): Focused, canonical comparison of OpenUI, Google A2UI, and Vercel json-render. - [Framework benchmark agent document](https://www.openui.com/benchmarks/framework/agent.md): Plain Markdown with format summaries and all model-format rows. - [Framework benchmark JSON](https://www.openui.com/benchmarks/framework/data.json): Focused machine-readable framework-comparison dataset. - [Benchmark agent document](https://www.openui.com/benchmarks/agent.md): Plain Markdown definitions, headline results, model board, provenance and distribution links. - [Benchmark JSON dataset](https://www.openui.com/benchmarks/data.json): Versioned machine-readable benchmark dataset. - [Benchmark JSON Schema](https://www.openui.com/benchmarks/data.schema.json): Field definitions and validation contract for the benchmark JSON dataset. - [OpenUI model-board CSV](https://www.openui.com/benchmarks/data.csv): One row per model with provider, family, score, pricing type and frontier membership. - [Benchmark methodology](https://www.openui.com/benchmarks/methodology): How the benchmark is run and scored. ## Optional - [Complete OpenUI documentation](https://www.openui.com/llms-full.txt): Full documentation in one plain-text response; it may exceed an LLM context window.