---
title: Component Library
description: The underlying headless component library.
icon: Library
---

## Overview

Fumadocs UI maintains support for both [Base UI](https://base-ui.com) and [Radix UI](https://radix-ui.com/primitives), while it uses Base UI by default.

The configuration may be different if you use Fumadocs CLI for customising components.

### Base UI

Base UI is the default component library. If you install manually, alias `fumadocs-ui` to the `@fumadocs/base-ui` package:

```json title="package.json"
{
  "dependencies": {
    "fumadocs-ui": "npm:@fumadocs/base-ui@latest",
    // make sure Base UI is already installed
    "@base-ui/react": "..."
  }
}
```

For Fumadocs CLI, this is the default `uiLibrary` value:

```json title="cli.json"
{
  "uiLibrary": "base-ui"
}
```

### Radix UI

You can opt-in to use Radix UI by installing the `fumadocs-ui` package directly:

```json title="package.json"
{
  "dependencies": {
    "fumadocs-ui": "latest"
  }
}
```

For Fumadocs CLI, configure it in your `cli.json` config:

```json title="cli.json"
{
  "uiLibrary": "radix-ui"
}
```
