Introduction
Yoga is a from-scratch, cross-platform UI framework in Go, drawn with WebGPU on the desktop and in the browser.
Yoga is a from-scratch, cross-platform UI framework in Go. It renders with WebGPU, through GLFW and wgpu-native on the desktop and through the browser's WebGPU from WebAssembly, and lays out with a pure-Go flex, grid and stack engine. The module is github.com/yogaui/yoga.
An app is a Go struct with one method, Body(c *ui.Ctx) ui.View, that returns a tree of views. Yoga calls it on every drawn frame, lays the tree out, and paints it. The same tree runs in a desktop window on macOS, Linux and Windows, in a browser tab, and headless in your tests.

What is in the box#
- Layout:
Column,Row,Grid,Stack,Scroll, splitters, drawers and floating corners. - Widgets: buttons, text fields with highlighting, completion and hover cards, selects, sliders, tabs, navigation, menus, tables, trees, file trees, virtual lists, Markdown, forms.
- Window services: dialogs, toasts, a command palette with key chords, and a pure-Go file dialog.
- Themes: 25 palettes, all checked against WCAG 2.1 AA, and a builder that makes your own from a few brand colors.
- Icons: Lucide, pre-rasterized and dropped by the linker when unused.
- Packaging: the
yogaCLI builds DMGs, AppImages, Windows zips and static web folders. - A code editor, as a separate module: yogaui/editor.
Where to go next#
- Installation: what you need, and the demos to run first.
- Your first app: the mental model and a first window.
- Layout and Controls: building a tree.
- Widget reference: every constructor and modifier.
- Packaging: ship it.