Config v6
The v3 default config with Tailwind-aligned scales and recipe-tree themes
Config v6 is the default configuration for Tamagui v3. Its spacing, sizing, radius, and type scales align with Tailwind CSS, while its themes use adaptive 11-shade ramps and composable relative levels.
yarn
npm
bun
pnpm
tamagui.config.ts
Defaults
spaceandsizeuse Tailwind’s 4px scale:1is 4,4is 16, and8is 32. Half steps,px, negative space tokens, and the larger Tailwind keys are included.- Radius tokens include Tailwind names from
xsthrough4xlandfull. - Font size and line height include Tailwind names from
xsthrough9xl. Their existing numeric font-config line heights remain absolute pixels. wandhare width and height shorthands.tokens.colorcontains the full Tailwind palette with names such asblue-500andslate-200.- Themes provide adaptive
color-1throughcolor-11, semantic generics, relativelevel2throughlevel4,inverse,accent,brand,red,yellow, andgreen. - Adaptive ramp numbers are steps relative to the active theme’s own scheme.
They are not Tailwind’s absolute
50through950shades. Only the spelling changed when these keys became hyphenated. - Shadows are per-theme values named
shadow-1throughshadow-7, as in v5. Dark themes use stronger shadows than light themes, andboxShadow="0 8px 24px shadow-4"readsshadow-4from the active theme. - Z-index has no configured token scale. Bare values resolve a matching token only when an application adds one. Otherwise, the literal unitless value is preserved.
The config does not choose a global component size. Each styled control owns
its own size variant inline and defaults to its md row.
This font-config behavior is distinct from v3 style authoring. A numeric
Tamagui lineHeight prop is a ratio on web and native. Font configuration uses
a numeric string such as "1.5" for a ratio and "24px" for an explicit
absolute length. No value changes meaning based on its magnitude.
Package entries
@tamagui/config/v6contains the complete static default config.@tamagui/config/v6-baseexports the color-independent scales, fonts, media, settings, andcreateV6Config(colors).@tamagui/config/v6-builderre-exports the recipe authoring API from@tamagui/themes/builder.
The static v6 entry imports generated themes. It does not run theme generation
in the browser.
Animations
No animation driver is bundled. Import exactly one driver from its neutral entry and add it to the config:
tamagui.config.ts
The other entries are animations-rn, animations-reanimated, and
animations-motion. See Choosing an Animation Driver
for their trade-offs.
Tailwind frontend
Use the separate Tailwind component frontend when you want className
authoring:
Regular components imported from tamagui continue to use Tamagui style props.
The shared v6 color tokens make absolute utilities such as bg-blue-500
resolve to the same values on web and native.
Tailwind leading utilities preserve the same distinction on both platforms. Spacing-scale leading and px arbitraries stay absolute, while unitless arbitraries are ratios:
Read v6 Colors to customize the palette and Creating Themes to customize the tree and scales.