📄 radixui/themes/docs/components/theme

File: theme.md | Updated: 11/15/2025

Source: https://www.radix-ui.com/themes/docs/components/theme

Radix Homepage

Made by WorkOS

Radix Homepage

Made by WorkOS

ThemesThemes PrimitivesPrimitives IconsIcons ColorsColors

Documentation Playground Blog

Overview

Getting started Styling Layout Releases Resources

Theme

Overview Color Dark mode Typography Spacing Breakpoints Radius Shadows Cursors

Layout

Box Flex Grid Container Section

Typography

Text Heading Blockquote Code Em Kbd Link Quote Strong

Components

Alert Dialog Aspect Ratio Avatar Badge Button Callout Card Checkbox Checkbox Group Checkbox Cards Context Menu Data List Dialog Dropdown Menu Hover Card Icon Button Inset Popover Progress Radio Radio Group Radio Cards Scroll Area Segmented Control Select Separator Skeleton Slider Spinner Switch Table Tabs Tab Nav Text Area Text Field Tooltip

Utilities

Accessible Icon Portal Reset Slot Theme Visually Hidden

Components

Theme

Wraps all or part of a React tree to provide theme configuration.

View source Report an issue

API Reference


For an overview of theming see the overview page .

| Prop | Type | Default | | --- | --- | --- | | asChild<br><br>Prop description | boolean | No default value | | hasBackground<br><br>Prop description | boolean | true | | appearance<br><br>Prop description | "inherit" \| "light" \| "dark" | "inherit" | | accentColor<br><br>Prop description | enum<br><br>See full type | "indigo" | | grayColor<br><br>Prop description | enum<br><br>See full type | "auto" | | panelBackground | "solid" \| "translucent" | "translucent" | | radius<br><br>Prop description | "none" \| "small" \| "medium" \| "large" \| "full" | "medium" | | scaling<br><br>Prop description | "90%" \| "95%" \| "100%" \| "105%" \| "110%" | "100%" |

Examples


Basic configuration

Wrap a component tree in the Theme component to provide or modify configuration for all children.

Feedback

Attach screenshot?

BackSend

<Box maxWidth="400px">
	<Card size="2">
		<Flex direction="column" gap="3">
			<Grid gap="1">
				<Text as="div" weight="bold" size="2" mb="1">
					Feedback
				</Text>
				<TextArea placeholder="Write your feedback…" />
			</Grid>
			<Flex asChild justify="between">
				<label>
					<Text color="gray" size="2">
						Attach screenshot?
					</Text>
					<Switch size="1" defaultChecked />
				</label>
			</Flex>
			<Grid columns="2" gap="2">
				<Button variant="surface">Back</Button>
				<Button>Send</Button>
			</Grid>
		</Flex>
	</Card>
</Box>

Nesting

Nest another theme to modify configuration for a specific subtree. Configuration is inherited from the parent.

Global

Feedback

Send

Child

Feedback

Send

Grandchild

Feedback

Send

<Card size="2">
	<Flex gap="6">
		<Flex direction="column" gap="3">
			<Heading as="h5" size="2">
				Global
			</Heading>
			<Grid gap="1">
				<Text as="div" weight="bold" size="2" mb="1">
					Feedback
				</Text>
				<TextArea placeholder="Write your feedback…" />
			</Grid>
			<Button>Send</Button>
		</Flex>

		<Theme accentColor="cyan" radius="full">
			<Card size="2">
				<Flex gap="6">
					<Flex direction="column" gap="3">
						<Heading as="h5" size="2">
							Child
						</Heading>
						<Grid gap="1">
							<Text as="div" weight="bold" size="2" mb="1">
								Feedback
							</Text>
							<TextArea placeholder="Write your feedback…" />
						</Grid>
						<Button>Send</Button>
					</Flex>

					<Theme accentColor="orange">
						<Card size="2">
							<Flex direction="column" gap="3">
								<Heading as="h5" size="2">
									Grandchild
								</Heading>
								<Grid gap="1">
									<Text as="div" weight="bold" size="2" mb="1">
										Feedback
									</Text>
									<TextArea placeholder="Write your feedback…" />
								</Grid>
								<Button>Send</Button>
							</Flex>
						</Card>
					</Theme>
				</Flex>
			</Card>
		</Theme>
	</Flex>
</Card>

Component overrides

Override configuration per component by passing any supported prop directly to that component.

Feedback

Attach screenshot?

BackSend

<Box maxWidth="400px">
	<Card size="2">
		<Flex direction="column" gap="3">
			<Grid gap="1">
				<Text as="div" weight="bold" size="2" mb="1">
					Feedback
				</Text>
				<TextArea placeholder="Write your feedback…" />
			</Grid>
			<Flex asChild justify="between">
				<label>
					<Text color="gray" size="2">
						Attach screenshot?
					</Text>
					<Switch
						size="1"
						color="orange"
						radius="full"
						defaultChecked
					/>
				</label>
			</Flex>
			<Grid columns="2" gap="2">
				<Button variant="surface">Back</Button>
				<Button color="cyan" radius="full">
					Send
				</Button>
			</Grid>
		</Flex>
	</Card>
</Box>

PreviousSlot

NextVisually Hidden

Edit this page on GitHub.