NativeWind: Tailwind CSS syntax for React Native, compiled at build time
The utility-first workflow you love from Tailwind CSS in your React Native applications.
At a glance
- What is it?
- NativeWind is a styling library, not a component library, that runs the Tailwind CSS compiler over your React Native styles during the build step. Here is how it installs, what it does with dark mode and container queries, and where it stops being the right tool.
- Who is it for?
- Adopt NativeWind if your team already writes Tailwind utility classes and you want the same mental model inside React Native, Expo or react-native-web, and you accept that styling is resolved in the build step rather than at runtime. Do not adopt it if you need container-type and style-based container queries, or if you expect a set of prebuilt components, since the README states plainly that NativeWind is a styling library and points elsewhere for component libraries.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository last received commits 15 days ago.
- What is it written in?
- Mainly JavaScript, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on September 26, 2026, and from our analysis. They are not legal advice.
Editorial analysis
The problem NativeWind solves for React Native teams
React Native ships its own styling system. You write JavaScript objects and hand them to StyleSheet.create, or you pass inline objects to the style prop. That works, and it is fast, but it does not look like the CSS most web developers already know. Class names, media queries, dark mode variants and the utility vocabulary of Tailwind have no direct equivalent in a StyleSheet object.
NativeWind targets that gap. It is a styling library that lets you write Tailwind classes in React Native components, and its stated goal is a consistent styling experience across all platforms while improving developer UX, component performance and code maintainability. The README is explicit about the audience boundary: NativeWind is not a component library. If you want buttons and cards that already use NativeWind, the README lists NativewindUI, React Native Reusables and gluestack as separate projects.
So the person this is for is a React Native developer who already thinks in utility classes, or a team shipping to iOS, Android and react-native-web from one codebase and unwilling to maintain two styling dialects. The person it is not for is someone who wants a design system out of the box.
Build-time compilation and the small runtime
The mechanism matters more than the syntax. NativeWind processes your styles during your application's build step, then uses what the README calls a minimal runtime to selectively apply reactive styles, giving device orientation changes and light or dark mode as examples. That split is the whole design: static class resolution happens ahead of time, and only the parts that must react to the device stay in the runtime.
The repository layout reflects the same pipeline. The package exposes separate entry points for the Babel plugin and for Metro, and the example project carries a babel.config.js, a metro.config.js, a postcss.config.mjs, a global.css and a nativewind-env.d.ts. Styles therefore travel through the normal bundler path rather than through a runtime interpreter. The package.json also declares sideEffects as false, which lets bundlers drop unused modules.
NativeWind also picks a style engine per platform, which the README describes as using the best style system for each platform, naming CSS StyleSheet and StyleSheet.create as examples. That is a real architectural claim, not marketing: the same class attribute can end up as a stylesheet rule on web and as a StyleSheet entry on native. The trade-off is that you are trusting the compiler to translate correctly, and debugging means looking at generated output rather than at a runtime object you wrote by hand.
Installing NativeWind and getting a first styled screen
The README does not inline installation steps for existing projects. It points to the getting-started guides on nativewind.dev for your respective stack. What it does inline is the Quickstart, which stands up a new Expo project through rn-new with NativeWind already wired up.
npx rn-new@latest --nativewind
npx rn-new@next --nativewindThe README labels the first command as Expo SDK 54 plus NativeWind v4.1, and the second as Expo SDK 54 plus NativeWind v5. Running either should scaffold a project where the Babel and Metro configuration is already in place, so the first screen you open is styled without further setup.
If you are adding NativeWind to an existing app instead, the relevant integration point is the withNativeWind helper, which the README shows in its answer about TypeScript generation:
withNativeWind(<config>, { disableTypeScriptGeneration: true })That option exists because NativeWind generates a types file by default, and teams that already declare compilerOptions.types want to switch that generation off. After wiring the config, you should expect a generated environment declaration file in the project (the example app has nativewind-env.d.ts) and a global CSS entry (global.css) that the build reads. If classes render but types do not resolve, the generation setting is the first thing to check.
What the feature list actually covers, and what it does not
The README enumerates support for CSS variables, dark mode, arbitrary classes, media queries, animations and transitions, container queries, pseudo classes such as hover, focus and active on compatible components, rem units, theme functions, nested functions, the React 18 Suspense API and custom CSS. It also supports styling children based on parent state through the group and group/<name> syntax, plus a children styles feature for layouts driven by a parent class.
Two caveats sit inside that list and are easy to skim past. First, container queries are qualified: container-type and style-based container queries are not supported. So the container query support is narrower than the phrase suggests, and if your layout strategy depends on container-type, NativeWind is the wrong tool for that layer. Second, pseudo classes are limited to compatible components, which means hover, focus and active are not universally available across every React Native primitive.
The README also notes that CSS StyleSheet or StyleSheet.create is chosen per platform, and that the runtime is deliberately small. That combination is the reason the feature list can be long while the runtime stays thin: most of the work has already happened before your app starts.
v4 versus v5, and which one you are actually installing
This is the part of the project most likely to trip up a new adopter, because the README answers the version question in two sentences that point in different directions. Asked when v5 is landing, it says NativeWind v5 is a release candidate, linking to nativewind.dev/v5. Asked whether v4 is safe to use, it answers yes.
The release history matches that split. There is a [email protected] release and a [email protected] release, both from 2026-09-14, and a 5.0.0-rc.0 release from 2026-09-13. The repository package.json, meanwhile, carries version 5.0.0-preview.4, which is neither of those published numbers. That is normal for a monorepo working ahead of its releases, but it means the version string in the source tree is not the version you get from npm.
The practical consequence: decide deliberately. The Quickstart offers both tracks, with rn-new@latest for v4.1 and rn-new@next for v5, so the command you run determines the branch you start on. Picking the next tag for a production app means adopting a release candidate, and the README does not document a rollback path from v5 to v4. The repository does carry a CHANGELOG.md, so that is where to look for the migration detail the README omits.
Where NativeWind is the wrong choice
The clearest boundary is the one the project draws itself. If you need a component library, NativeWind will not give you one, and the README redirects you to NativewindUI for a native feel per platform, React Native Reusables for universal shadcn/ui, or gluestack for customizable cross-platform components. Choosing NativeWind means choosing to build or import the components separately.
The second boundary is container queries. Because container-type and style-based container queries are not supported, teams whose responsive strategy is built on those primitives should not expect NativeWind to carry it.
The third is subtler and comes from the architecture rather than a stated limit. Styles are computed at build time, so anything that must be decided from runtime data has to go through the minimal runtime or through inline styles. Teams that generate class names dynamically at runtime, for example by concatenating user input into a class string, are working against the grain of a build-time compiler. And because the toolchain involves Babel, Metro and PostCSS configuration, a project with an unusual or heavily customized bundler setup will spend its first hours on configuration rather than on styling.
How NativeWind differs from plain Tailwind CSS
The obvious alternative is Tailwind CSS itself, and the difference is not cosmetic. Tailwind emits a CSS file that a browser parses at runtime and applies through the cascade. NativeWind runs the Tailwind compiler over your styles during the build step and then maps the result onto each platform's native style system, using CSS StyleSheet on web and StyleSheet.create on native. There is no cascade on iOS or Android to fall back on, which is why parent state modifiers such as group and the children styles feature exist: they reconstruct relationships that CSS would express with selectors.
That also explains the feature list. Media queries, rem units, theme functions and nested functions all have CSS semantics, and NativeWind reproduces them rather than inheriting them for free. Some things do not survive the mapping, and container-type is the documented example.
If you are comparing against another React Native styling approach, the question to ask is where the work happens. NativeWind's answer is the build step, with a small runtime for reactive cases. That is a good fit for a static, utility-class codebase and a poor fit for one whose styles are computed while the app runs.
Licence and the cost of keeping up
NativeWind is MIT licensed, both in the repository metadata and in the package.json license field. MIT is permissive, so the usual obligations around attribution and the licence text apply, but nothing here suggests a copyleft or commercial restriction. This is a description of the licence, not legal advice; read the LICENSE file in the repository if the terms matter to your organisation.
On maintenance, the repository is not archived and the last push was on 2026-09-15, which is recent. The published artifacts move together: [email protected] and [email protected] were both released on 2026-09-14, and 5.0.0-rc.0 the day before. The presence of a separate react-native-css-interop package, which the package.json exports and the release list both show, is worth noting for upgrade planning: interop changes and NativeWind changes can land in the same window.
The upgrade cost is the configuration surface. NativeWind touches Babel, Metro and PostCSS, and it generates a TypeScript declaration file unless you pass disableTypeScriptGeneration. Every one of those is a place where a version bump can require a change. The repository ships a CHANGELOG.md and a DEVELOPMENT.md, and the README links a contributing guide, so the information exists, but the README itself does not document a rollback procedure for either the v4 to v5 move or a failed upgrade.
Editorial conclusion
Adopt NativeWind if your team already writes Tailwind utility classes and you want the same mental model inside React Native, Expo or react-native-web, and you accept that styling is resolved in the build step rather than at runtime. Do not adopt it if you need container-type and style-based container queries, or if you expect a set of prebuilt components, since the README states plainly that NativeWind is a styling library and points elsewhere for component libraries. Before committing, verify which branch you are on: the README answers whether v4 is safe to use with a yes, while v5 is described as a release candidate, and the npm release history shows both a 4.2.7 line and a 5.0.0-rc.0. Then confirm that withNativeWind in your babel or metro configuration matches the version you installed.
Frequently asked questions
Is NativeWind the same as Tailwind CSS?
No. NativeWind uses the Tailwind CSS compiler and the utility-class syntax, but it is a styling library for React Native that processes styles at build time and applies them through each platform's native style system, such as CSS StyleSheet or StyleSheet.create.
How do I install NativeWind in a React Native Expo project?
The README does not inline installation steps for existing projects and instead points to the getting-started guides on nativewind.dev. For a new project, the Quickstart uses rn-new: npx rn-new@latest --nativewind for Expo SDK 54 with NativeWind v4.1, or npx rn-new@next --nativewind for Expo SDK 54 with NativeWind v5.
How do I use NativeWind in React Native?
You write Tailwind utility classes in your components, and NativeWind compiles them during the build step and uses a minimal runtime to apply reactive styles such as device orientation changes and light or dark mode. The integration runs through Babel and Metro configuration.
How do I set up NativeWind in an Expo project?
The Quickstart stands up a pre-configured Expo project with NativeWind already wired in, using npx rn-new@latest --nativewind or npx rn-new@next --nativewind. Both target Expo SDK 54; the difference is the NativeWind version they install.
How do I install NativeWind in a React Native CLI project?
The README does not provide CLI-specific steps; it directs existing projects to the installation guides on nativewind.dev for their respective stack. The only inline commands are the Expo Quickstart ones built on rn-new.
Can I add NativeWind to an existing React Native app?
Yes, the README says to use the getting-started guides to configure NativeWind for your respective stack rather than the Quickstart, which is for new projects. The configuration goes through Babel and Metro, with withNativeWind as the integration helper.
Official sources
Add this badge to your README
If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.
[](https://hysenlabs.com/projects/nativewind-nativewind)