A cross-platform native UI engine where app logic runs in Go and each platform draws with its own native views.
marc2332/freya
A cross-platform, native, declarative GUI library for building desktop and mobile apps in Rust.
- Stars
- 3,307
- Forks
- 152
- Open issues
- 42
- Last commit
- 9 hours ago
What is it?
Freya is a declarative GUI library for Rust that renders native interfaces across desktop and other platforms. Developers describe UI as Rust functions and components, and state set with hooks such as use_state automatically triggers re-rendering of the parts that depend on it. It is built on its own reactive core rather than Dioxus, starting with version 0.4.
The library ships with a set of ready-made components, including Button, Switch, Slider, VirtualScrollView, Calendar and ColorPicker. Optional feature flags add a code editor based on tree-sitter, a Markdown viewer, routing, global state through freya-radio, Fluent-based i18n, Material Design styling, HTML/CSS rendering via Blitz, a terminal emulator with PTY support, and plotting through Plotters.
Freya also offers headless testing through freya-testing, which can simulate clicks and render the UI to an image file, along with a devtools app for inspecting the component tree.
Key features
- 01Declarative component model with hooks-based state that re-renders dependent UI automatically.
- 02Built-in components such as Button, Switch, Slider, Calendar and VirtualScrollView.
- 03Optional code editor using Rope for text and tree-sitter for syntax highlighting.
- 04Routing, global state management, and Fluent-based internationalization via feature flags.
- 05Embedded terminal emulator with PTY support and HTML/CSS rendering through Blitz.
- 06Headless testing with the ability to render the UI to a file.
Use cases
- Building native desktop tools or utilities in pure Rust.
- Creating developer tools such as code editors or terminal-based interfaces.
- Prototyping data visualization dashboards with the plotting feature.
- Writing UI tests for Rust GUI applications without opening a window.
Quick start
- 1
Add Freya to your Cargo.toml
- 2
Clone the repo with submodules
git clone --recurse-submodules https://github.com/marc2332/freya.git - 3
Change into the project directory
cd freya - 4
Run an example
cargo run --example counter
Things to know
- Requires a Rust development setup and git submodules to run the examples.
- Windows windows-gnu builds may hit compile errors.
In collections
Topics
FAQ
- What is freya?
- A cross-platform, native, declarative GUI library for building desktop and mobile apps in Rust. Freya is a declarative GUI library for Rust that renders native interfaces across desktop and other platforms. Developers describe UI as Rust functions and components, and state set with hooks such as use_state automatically triggers re-rendering of the parts that depend on it. It is built on its own reactive core rather than Dioxus, starting with version 0.4.
- Is freya free to use? What license does it have?
- freya is open source under the MIT license. Check the license terms before using it in commercial products.
- Is freya still maintained?
- Actively maintained. The last commit to freya was on Nov 6, 2026.
- What can I use freya for?
- Building native desktop tools or utilities in pure Rust. Creating developer tools such as code editors or terminal-based interfaces. Prototyping data visualization dashboards with the plotting feature. Writing UI tests for Rust GUI applications without opening a window.
- How do I install freya?
- Add Freya to your Cargo.toml Clone the repo with submodules: git clone --recurse-submodules https://github.com/marc2332/freya.git Change into the project directory: cd freya Run an example: cargo run --example counter
- Where can I get freya?
- The source code and installation instructions are on GitHub: https://github.com/marc2332/freya
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
Slint is a declarative GUI toolkit for building native user interfaces in Rust, C++, JavaScript, or Python apps.
An Elixir library for building native desktop apps with declarative UI rendered by the Rust-based GPUI framework.
A cross-platform .NET UI framework for building desktop, mobile, embedded and WebAssembly apps with C# and XAML.
Python framework for building web, desktop and mobile apps with a Flutter-based UI, no frontend experience needed.
A Rust engine for native cross-platform UI, letting you write apps in Rust or TSX and render with each platform's own widgets.