About this project

OpenUI is an open-source framework for building Generative UI applications, where AI models produce structured, interactive user interfaces rather than plain text. At its core is OpenUI Lang, a compact, streaming-first language designed specifically for model-generated UI output. The framework is renderer-agnostic, meaning it is not tied to a single frontend framework, though it ships with official React support and community-maintained bindings for Vue 3 and Svelte 5. The central workflow is straightforward: developers define or reuse a component library (charts, forms, tables, layouts, etc.), OpenUI generates a system prompt from that library, the prompt is sent to an LLM, and the model streams OpenUI Lang output back to the client where a renderer progressively parses and renders the UI as tokens arrive. This streaming-first design means users see the interface build up in real time rather than waiting for a complete response. A key differentiator is token efficiency. Benchmarks measured with tiktoken (GPT-5 encoder) across seven UI scenarios show OpenUI Lang uses up to 67% fewer tokens than equivalent JSON-based formats, with an average reduction of about 52.8% compared to Vercel's JSON-Render and 51.7% compared to Thesys C1 JSON. Lower token counts translate to reduced latency, lower API costs, and faster time-to-first-pixel. The project is organized as a monorepo with multiple packages. @openuidev/lang-core provides framework-agnostic parsing, prompt generation, and runtime evaluation with no React, Vue, or Svelte dependency. @openuidev/react-lang handles React rendering runtimes, component library definitions, and prompt generation. @openuidev/react-headless offers headless chat state management and streaming adapters for teams that want to bring their own UI. @openuidev/react-ui provides prebuilt chat layouts and two built-in component libraries for the fastest path to a working chat experience. @openuidev/react-email adds React Email component definitions for model-generated emails. @openuidev/langchain integrates with LangChain and LangGraph agents, streaming OpenUI through AG-UI. @openuidev/browser-bundle ships a prebuilt script-tag bundle for CDN, iframe, and no-build embeds. @openuidev/cli scaffolds new projects and generates system prompts or JSON schemas from library definitions. Component contracts are defined with Zod schemas, giving typed props and structure up front. The framework supports built-in data fetching, multi-platform output (web, mobile, email), and consistent output formatting. A Playground is available at openui.com/playground for live experimentation with the default component library. OpenUI also ships an Agent Skill that integrates with AI coding assistants like Claude Code, Codex, Cursor, and Copilot, covering component library design, OpenUI Lang syntax, system prompt generation, the Renderer, SDK packages, and debugging malformed LLM output. The project is licensed under MIT and maintained by Thesys, with an active Discord community and a growing list of adopters.