NativeDesktop

NativeDesktop

One Rust view tree that renders as native AppKit controls on macOS and through GPUI on Linux, Windows, and the web.

NativeDesktop is a toolkit for desktop apps written in Rust. You describe a window as a tree of views and elements, and each platform's backend turns that tree into the controls its OS draws.

The counter below is all of hello: a struct with a render method and a button. The same code runs on every target:

Your app never names a backend. scaffold(), toolbar(), and button() say what the window contains, and the backend decides how that looks on its OS. When a platform has no native version of something, the framework draws it from the same theme tokens.

Example: Hello. The smallest app: a toolbar button, a count and window controls placed by coordinates. Source in examples/hello. It also runs live in the docs app.
Hello on macOS

Captured on macOS 27.0, 2026-10-22.

Hello on Linux

Captured on NixOS 26.11 (Zokor), Hyprland, 2026-10-22.

Hello on Windows

Captured on Windows 11 26H2, 2026-10-22.

Built for agents

The framework is designed so that a coding agent can build a good app on the first pass and prove that it works. nd new writes a project with a CLAUDE.md, a tier 1 test and an appearance audit. nd check fails on literal colors, text below WCAG contrast, unwrap, and framework lints. nd test runs the same view with no window. The agent pages list the patterns to copy and the mistakes to avoid. They're written for people too; nothing in them is agent-only.

Where to go next

  1. Getting started: install the nd CLI, then create, run, and test an app.
  2. Programming model: views, entities and the retained tree.
  3. Elements, state and actions and keys: the vocabulary you use every day.
  4. Components and the examples: what ships and how it looks.