Skip to content

Tamagui

A TypeScript library for building React and React Native UIs that share styling and code.

Stars
14.3k
Forks
627
Licence
MIT
Language
TypeScript
Last update
4 days ago
Type
Library

What it is

Tamagui is a set of open-source libraries for building user interfaces that run on both the web (React) and phones (React Native) from one shared codebase. It includes a styling library, an optional ready-made UI kit, and a compiler that rewrites styled components into faster output on each platform. Developers use it to share more code between web and native apps without giving up performance.

  • Build a set of components once and use them in both a web app and a React Native app
  • Use the base views and styled function to start with simple styling and add the compiler later
  • Create a starter project with npm create tamagui@latest and explore a learning example or a production monorepo

Great for

  • Teams building the same app for web and native with React
  • Developers who want shared styling across React Native and react-native-web
  • Projects that want an optional compiler to speed up styled components
  • Developers who can set it up gradually inside an existing app

Not ideal for

  • People who only need a plain website and no React (the project is built around React)
  • Beginners without React or TypeScript experience, since the setup assumes both
  • Projects that want a single, fixed design with no customization (the UI kit is optional and configurable)
Step-by-step guide: how to use TamaguiInstall, first run, examples, tips and FAQs

How to get it

  1. 1

    Install with a package manager

    You'll need: Node.js · npm

    Create a new starter project

    npm create tamagui@latest
  2. 2

    Run it

    • Run npm create tamagui@latest and choose a starter
    • Open the generated project and follow its README to start the dev server
    • Edit a styled component and check the result on web or native
    • Read the documentation at tamagui.dev to learn the styling API
  3. 3

    Get the most out of it

    • Start with the starter that best matches your needs, from a simple example to a production monorepo
    • Enable the optimizing compiler (@tamagui/static) to flatten styled components for better performance
    • Use the optional tamagui UI kit or just @tamagui/core for styling only
    • Refer to the docs at tamagui.dev for configuration details

Downloads

Strengths

  • Aims for shared code across web and native while keeping platform-specific performance, per the README
  • Works gradually, so you can adopt it in parts of an existing project
  • Released under the permissive MIT license

Trade-offs

  • The README's performance claims (such as a Lighthouse gain on its homepage) are the project's own measurements and were not independently verified here
  • Compile-time and runtime behavior adds setup complexity compared with simple styling libraries
  • The README is truncated, so details on setup and configuration are limited in this analysis

How it compares

ProjectStarsTypeLevelUpdatedBest for
tamagui (this)14.3kLibraryintermediate4 days agoTeams building the same app for web and native with React
react-native-paper14.5kLibraryintermediate4 days agoReact Native developers who want ready-made Material Design components
react-native-elements25.9kLibraryintermediate6 months agoReact Native developers who want ready-made UI components
react-native-web22.2kLibraryintermediate4 days agoDevelopers who already use React Native and want the same components on the web
storybook91.4kDev toolintermediate4 days agoFrontend teams building a shared component library or design system
NativeBase20.4kLibraryintermediate9 months agoTeams maintaining an existing app already built on NativeBase

Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.