Install Radix Themes and start building your project in minutes.
Getting up and running is quick and easy.
Install the package from your command line.
npm install @radix-ui/themes
Import the global CSS file at the root of your application.
import '@radix-ui/themes/styles.css';
Add Theme
to your application, wrapping the root component inside of body
.
import { Theme } from '@radix-ui/themes';
export default function () {
return (
<html>
<body>
<Theme>
<MyApp />
</Theme>
</body>
</html>
);
}
You are now ready to use Radix Themes components.
import { Flex, Text, Button } from '@radix-ui/themes';
export default function MyApp() {
return (
<Flex direction="column" gap="2">
<Text>Hello from Radix Themes :)</Text>
<Button>Let's go</Button>
</Flex>
);
}
Configuration is managed and applied via the Theme component.
Pass configuration to the Theme
to customize appearance.
<Theme accentColor="crimson" grayColor="sand" radius="large" scaling="95%">
<MyApp />
</Theme>
ThemePanel
is a drop in component that allows you to preview the theme configuration in real time.
Visit the component playground to see it in action.
To add it to your app, import it from the package and drop it inside your root Theme
.
import { Theme, ThemePanel } from '@radix-ui/themes';
export default function () {
return (
<Theme>
<MyApp />
<ThemePanel />
</Theme>
);
}
Get the most out of Radix Themes by exploring more concepts and features.
Anatomy of a theme and how to create the perfect style for your app.
Learn how variants, radii and shadows influence your apps visual style.
Understand the color system and its application in your theme.
Integrate a great looking dark mode into your app using appearances.
Add custom typefaces and fine tune typographic details.
Leverage the built-in responsive design utilities and prop syntax.