Tamagui is a style library and UI kit that enables developers to write React code that runs on both web and React Native with full parity.
The core problem Tamagui solves is the typical performance and code quality degradation that occurs when sharing code between web and native platforms. It addresses this through an optimizing compiler that runs at build time to generate platform-specific output. On the web, the compiler transforms styled components into simple divs paired with atomic CSS. On React Native, it hoists style objects and outputs View components. The compiler handles complex logic and cross-module imports, flattening the majority of styled components in real-world usage. The tool works both at compile time and runtime, allowing gradual adoption starting with basic views and the styled function.
Tamagui suits teams building applications that target both web and native platforms simultaneously and want to maximize code reuse without performance penalties. The project provides starter templates ranging from simple learning examples to production-ready monorepos. The README does not compare Tamagui to alternative approaches, so no comparative guidance can be offered. The core library is available as separate packages: @tamagui/core for universal styling, @tamagui/static for the optimizing compiler, and tamagui as a complete UI kit that adapts across platforms.
The project maintains active commit activity and hosts an engaged community on Discord. Documentation is comprehensive and centralized on the project website. The team provides multiple entry points for contribution, including a dedicated contributing guide and clear documentation source locations for those wanting to improve the docs.