
aetherux
io.github.google/aetherux
Headless preview, design fitting, layout audits, and auto-fix for SwiftUI, Compose, Flutter, React
Documentation
Aether
Verify, repair, and embed AI-generated UI—natively.
Disclaimer: This isn't an officially supported Google product.
Aether compiles Jetpack Compose, SwiftUI, React (JSX), Flutter, and A2UI in pure Rust for a sub-100 ms verification loop. Render, accessibility-audit, and pixel-fit AI-generated UI headlessly—ahead of time in your IDE or inline at request time—or embed live server-generated UI inside an untrusted capability sandbox across Android, iOS, Web, Flutter, and React Native.

Verify AI-generated UI
@aetherux/mcp works on Jetpack Compose, SwiftUI, React, and Flutter files
with no Aether runtime required. Add it to your agent's MCP configuration (for
example, .mcp.json or ~/.gemini/settings.json):
{
"mcpServers": {
"aether": { "command": "npx", "args": ["-y", "@aetherux/mcp"] }
}
}
Pass standalone: true (CLI: --standalone) when checking code in an app that
doesn't use the Aether runtime. Your agent gets six core verification tools:
aether_inspect: Measures any PNG or Figma export into a layout and color calibration table, or audits a rendered screen (AE6101throughAE6204).aether_validate: Checks syntax, semantics, standalone compatibility (AE2119), and sandbox rules across.kt,.swift,.tsx,.dart,.md, and.a2uifiles.aether_fix: Repairs mechanical compiler findings from the syntax tree using zero model tokens.aether_fit: Tunes numeric style literals (fontSize,padding,gap,borderRadius,width,height) to match a mock PNG or clear layout violations using zero model tokens. Passrenderer(playwright,swiftui,paparazzi, orflutter) to polish against the platform's own renderer after Aether's fast pass (see native render adapters).aether_render: Renders a single viewport or a four-panel responsive contact sheet (light, dark, large text, and RTL) with golden diff overlays.aether_sim: Runs scripted taps, text input, and navigation, returning a step filmstrip PNG and state diffs.
Run the same checks from scripts or CI with npx @aetherux/mcp render ... (or
install the standalone binary via sh install.sh --flavor mcp). Install
optional CJK and emoji fonts with npx @aetherux/mcp fonts install cjk emoji.
See Verify AI-generated UI.
Embed AI-generated UI in an existing app
Compile request-time LLM-generated screens in 5 to 38 ms into data-only
Protocol Buffers or stream live A2UI into
AetherHost (<aether-host> on the web) inside an untrusted capability
sandbox—isolating state to sandbox.*, blocking host credentials and unlisted
endpoints, and rendering with native platform controls rather than a WebView.
Start with Embed AI-generated UI or go straight to your platform guide: Android, iOS, Web, Flutter, or React Native.
Building a whole app from one shared codebase instead? See
Create and preview an app to
scaffold a project with aether init, preview in Aether Studio and on your
phone, and ship to app stores.
Benchmarks
Aether's benchmarks measure warm
MCP latency on a 43-node interactive screen, code generation across 50 tasks
(gemini-3.8-flash), and compressed release binary deltas:
- Agent loop speed:
5 to 38 mscompile ·43 to 73 msPNG render ·37 to 67 ms(0model turns) validate, auto-fix, and re-render. - Code generation evals:
100%pass rate across Compose, SwiftUI, JSX, and Flutter after the repair loop (95.2% to 97.1%design-to-code similarity). - Incremental runtime cost:
2.4 to 3.3 MBon mobile (+1.5 to 1.6 MBwith embedded JS) ·7.6 to 37.9 kBon the web ·2 to 96 mscold start to first rendered surface.
What Aether isn't
- A compiler for arbitrary Kotlin, Swift, TypeScript, or Dart code. Aether compiles the declarative UI subset of each language. Platform APIs and business logic stay in your app behind host functions and native views. See Dialect differences and lean mode.
- A replacement for Compose, SwiftUI, or Flutter. Aether renders with them and embeds in apps built with them.
- An alternative to A2UI. A2UI is the protocol for agent-generated UI; Aether is a native renderer and authoring toolchain for it.
Documentation
Read the guides in apps/aetherux/src/docs/ or open
the local docs portal (aether dev → http://localhost:8080/_aether/docs):
- Start: Aether overview · Why Aether
- Verify AI-generated UI: Verify AI-generated UI · Fit UI to a design mock
- Embed AI-generated UI: Embed AI-generated UI · Stream live A2UI surfaces · Android · iOS · Web · Flutter · React Native · Host functions · Native views
- Deploy to production: Deploy to CDN and static hosts · Configure the server · Authentication · Run experiments
- Build a new app: Create and preview an app · Build native release packages · Routes, cache, and prefetch · Push notifications
- Reference: Dialect differences · CLI reference · Architecture · Contributing and repo layout
Security
Report vulnerabilities at https://g.co/vulnz; see SECURITY.md.
Eligibility for the
Google Open Source Software Vulnerability Rewards Program
is determined by the
Google Open Source Software Vulnerability Reward Program Rules.
Contributing
We welcome issues and pull requests. Read CONTRIBUTING.md
to build from source, and follow our code of conduct. Ask
questions in
GitHub Discussions, and see
CHANGELOG.md for what's new.
License
Apache License 2.0. See the LICENSE file for details.
@aetherux/mcpnpm install @aetherux/mcp