https://github.com/dioxuslabs/dioxus
Fullstack app framework for web, desktop, mobile, and more.
https://github.com/dioxuslabs/dioxus
android css desktop html ios native react rust ssr ui virtualdom wasm web
Last synced: 24 days ago
JSON representation
Fullstack app framework for web, desktop, mobile, and more.
- Host: GitHub
- URL: https://github.com/dioxuslabs/dioxus
- Owner: DioxusLabs
- License: apache-2.0
- Created: 2021-01-15T01:57:26.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2025-04-30T22:39:27.000Z (5 months ago)
- Last Synced: 2025-04-30T23:29:32.525Z (5 months ago)
- Topics: android, css, desktop, html, ios, native, react, rust, ssr, ui, virtualdom, wasm, web
- Language: Rust
- Homepage: https://dioxuslabs.com
- Size: 40 MB
- Stars: 27,171
- Watchers: 136
- Forks: 1,087
- Open Issues: 424
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE-APACHE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
- awesome-game-engine-dev - Dioxus - Cross-platform, React-like gui library. (Libraries / Rust)
- awesome-trevor - Dioxus - React-like GUI library for desktop, web, mobile, TUI, and more (Programming / Rust 🦀)
- awesome-rust - DioxusLabs/dioxus - a portable, performant, and ergonomic framework for building cross-platform user interfaces in Rust.  (Libraries / GUI)
- awesome-rust-cn - DioxusLabs/dioxus - (库 Libraries / GUI GUI)
- awesomeLibrary - dioxus - Fullstack GUI library for desktop, web, mobile, and more. (语言资源库 / rust)
- fucking-awesome-rust - DioxusLabs/dioxus - a portable, performant, and ergonomic framework for building cross-platform user interfaces in Rust.  (Libraries / GUI)
- awesome-rust - DioxusLabs/dioxus - a portable, performant, and ergonomic framework for building cross-platform user interfaces in Rust.  (Libraries / GUI)
README
![]()
![]()
![]()
✨ Dioxus 0.7 is in alpha - test it out! ✨
Build for web, desktop, and mobile, and more with a single codebase. Zero-config setup, integrated hot-reloading, and signals-based state management. Add backend functionality with Server Functions and bundle with our CLI.
```rust
fn app() -> Element {
let mut count = use_signal(|| 0);rsx! {
h1 { "High-Five counter: {count}" }
button { onclick: move |_| count += 1, "Up high!" }
button { onclick: move |_| count -= 1, "Down low!" }
}
}
```## ⭐️ Unique features:
- Cross-platform apps in three lines of code (web, desktop, mobile, server, and more)
- [Ergonomic state management](https://dioxuslabs.com/blog/release-050) combines the best of React, Solid, and Svelte
- Built-in featureful, type-safe, fullstack web framework
- Integrated bundler for deploying to the web, macOS, Linux, and Windows
- Subsecond Rust hot-patching and asset hot-reloading
- And more! [Take a tour of Dioxus](https://dioxuslabs.com/learn/0.6/).## Instant hot-reloading
With one command, `dx serve` and your app is running. Edit your markup, styles, and see changes in milliseconds. Use our experimental `dx serve --hotpatch` to update Rust code in real time.
![]()
## Build Beautiful Apps
Dioxus apps are styled with HTML and CSS. Use the built-in TailwindCSS support or load your favorite CSS library. Easily call into native code (objective-c, JNI, Web-Sys) for a perfect native touch.
![]()
## Experimental Native Renderer
Render using web-sys, webview, server-side-rendering, liveview, or even with our experimental WGPU-based renderer. Embed Dioxus in Bevy, WGPU, or even run on embedded Linux!
![]()
## First-party primitive components
Get started quickly with a complete set of primitives modeled after shadcn/ui and Radix-Primitives.
![]()
## First-class Android and iOS support
Dioxus is the fastest way to build native mobile apps with Rust. Simply run `dx serve --platform android` and your app is running in an emulator or on device in seconds. Call directly into JNI and Native APIs.
![]()
## Productive, typesafe, fullstack web framework
Directly call your backend from your frontend with our built-in type-safe RPC using [`server_fn`](http://crates.io/crates/server_fn). Supports streaming, suspense, bundle splitting, websockets, and more.
```rust
fn app() -> Element {
let mut fortune = use_signal(|| "Fetch a fortune!");
rsx! {
h1 { "{fortune}" }
button {
onclick: move |_| async move {
fortune.set(fetch_fortune().await.unwrap());
}
}
}
}#[server]
async fn fetch_fortune() -> ServerFnResult {
"Dioxus is super productive!".to_string()
}
```## Bundle for web, desktop, and mobile
Simply run `dx bundle` and your app will be built and bundled with maximization optimizations. On the web, take advantage of [`.avif` generation, `.wasm` compression, minification](https://dioxuslabs.com/learn/0.6/guides/assets), and more. Build WebApps weighing [less than 50kb](https://github.com/ealmloff/tiny-dioxus/) and desktop/mobile apps less than 5mb.
![]()
## Fantastic documentation
We've put a ton of effort into building clean, readable, and comprehensive documentation. All html elements and listeners are documented with MDN docs, and our Docs runs continuous integration with Dioxus itself to ensure that the docs are always up to date. Check out the [Dioxus website](https://dioxuslabs.com/learn/0.6/) for guides, references, recipes, and more. Fun fact: we use the Dioxus website as a testbed for new Dioxus features - [check it out!](https://github.com/dioxusLabs/docsite)
![]()
## Modular and Customizable
Build your own renderer, or use a community renderer like [Freya](http://freyaui.dev). Use our modular components like RSX, VirtualDom, Blitz, Taffy, and Subsecond.
![]()
## Community
Dioxus is a community-driven project, with a very active [Discord](https://discord.gg/XgGxMSkvUM) and [GitHub](https://github.com/DioxusLabs/dioxus/issues) community. We're always looking for help, and we're happy to answer questions and help you get started. [Our SDK](https://github.com/DioxusLabs/dioxus-std) is community-run and we even have a [GitHub organization](https://github.com/dioxus-community/) for the best Dioxus crates that receive free upgrades and support.
![]()
## Full-time core team
Dioxus has grown from a side project to a small team of fulltime engineers. Thanks to the generous support of FutureWei, Satellite.im, the GitHub Accelerator program, we're able to work on Dioxus full-time. Our long term goal is for Dioxus to become self-sustaining by providing paid high-quality enterprise tools. If your company is interested in adopting Dioxus and would like to work with us, please reach out!
## Supported Platforms
Web
- Render directly to the DOM using WebAssembly
- Pre-render with SSR and rehydrate on the client
- Simple "hello world" at about 50kb, comparable to React
- Built-in dev server and hot reloading for quick iteration
Desktop
- Render using Webview or - experimentally - with WGPU or Freya (Skia)
- Zero-config setup. Simply `cargo run` or `dx serve` to build your app
- Full support for native system access without IPC
- Supports macOS, Linux, and Windows. Portable <3mb binaries
Mobile
- Render using Webview or - experimentally - with WGPU or Skia
- Build .ipa and .apk files for iOS and Android
- Call directly into Java and Objective-C with minimal overhead
- From "hello world" to running on device in seconds
Server-side Rendering
- Suspense, hydration, and server-side rendering
- Quickly drop in backend functionality with server functions
- Extractors, middleware, and routing integrations
- Static-site generation and incremental regeneration
## Running the examples
> The examples in the main branch of this repository target the git version of dioxus and the CLI. If you are looking for examples that work with the latest stable release of dioxus, check out the [0.6 branch](https://github.com/DioxusLabs/dioxus/tree/v0.6/examples).
The examples in the top level of this repository can be run with:
```sh
cargo run --example
```However, we encourage you to download the dioxus-cli to test out features like hot-reloading. To install the most recent binary CLI, you can use cargo binstall.
```sh
cargo binstall dioxus-cli@0.7.0-rc.0 --force
```If this CLI is out-of-date, you can install it directly from git
```sh
cargo install --git https://github.com/DioxusLabs/dioxus dioxus-cli --locked
```With the CLI, you can also run examples with the web platform. You will need to disable the default desktop feature and enable the web feature with this command:
```sh
dx serve --example --platform web -- --no-default-features
```## Contributing
- Check out the website [section on contributing](https://dioxuslabs.com/learn/0.6/contributing).
- Report issues on our [issue tracker](https://github.com/dioxuslabs/dioxus/issues).
- [Join](https://discord.gg/XgGxMSkvUM) the discord and ask questions!## License
This project is licensed under either the [MIT license] or the [Apache-2 License].
[apache-2 license]: https://github.com/DioxusLabs/dioxus/blob/master/LICENSE-APACHE
[mit license]: https://github.com/DioxusLabs/dioxus/blob/master/LICENSE-MITUnless you explicitly state otherwise, any contribution intentionally submitted
for inclusion in Dioxus by you, shall be licensed as MIT or Apache-2, without any additional
terms or conditions.