gpui-component
Rust GUI components for building fantastic cross-platform desktop application by using GPUI.
A library of 60+ ready-made desktop UI components for Rust apps built with GPUI, the same rendering engine behind the Zed code editor, covering everything from buttons to a full code editor.
GPUI Component is a library of over 60 user interface building blocks for making desktop applications in Rust, using a framework called GPUI (the same rendering engine behind the Zed code editor). It targets developers who want to build cross-platform desktop apps for macOS, Windows, and the web that look modern rather than plain.
The components range from everyday controls like buttons and text inputs to more complex structures like resizable panel layouts (called Dock), data tables that can handle hundreds of thousands of rows without slowdown, and a full code editor with syntax highlighting and language-server protocol support for features like code completion and error display. Markdown and basic HTML can also be rendered inline. The visual style draws from macOS and Windows native controls combined with the shadcn/ui design language.
Setting up a project requires pulling GPUI itself from the Zed repository (it is not published to Rust's package registry separately), plus this component library. A basic hello-world window with a button takes about twenty lines of code. Icons are not bundled; developers supply their own SVG files named according to the library's naming convention.
The project includes a gallery application that shows every component in action. Developers can run it locally with a single cargo command, or browse it in a web browser via a WASM build. Focused examples cover the code editor, dock layout, Markdown rendering, and a real-time system monitor with live charts.
Compared to other Rust GUI libraries like Iced or egui, GPUI Component offers a broader component set, built-in charts, a more advanced code editor, and mixed Markdown-plus-HTML rendering. The tradeoff is a larger minimum binary size (around 12 MB) and a dependency on GPUI, which is tightly coupled to the Zed project. The license is Apache 2.0.
Where it fits
- Build a cross-platform desktop app for macOS and Windows in Rust with a modern UI without designing components from scratch.
- Add a code editor with syntax highlighting and autocomplete to a Rust desktop application.
- Display a high-performance data table with hundreds of thousands of rows in a Rust GUI app.
- Render Markdown or basic HTML inline inside a GPUI-based Rust application.