---
title: "Multi Select"
description: "Composable multi-select primitives with searchable options, removable animated tokens, and a morphing collision-aware panel."
category: "Components"
publishedAt: "2026-08-29"
updatedAt: "2026-11-25"
documentation: "https://beui.dev/components/motion/multi-select"
markdown: "https://beui.dev/components/motion/multi-select.md"
license: "MIT"
---

# Multi Select

> Composable multi-select primitives with searchable options, removable animated tokens, and a morphing collision-aware panel.

## Install

```bash
npx shadcn@latest add @beui/multi-select
```

## Dependencies

- `clsx`
- `lucide-react`
- `motion`
- `react`
- `react-dom`
- `tailwind-merge`

## Usage

```tsx
"use client";

import { Circle } from "lucide-react";
import {
  MultiSelect,
  MultiSelectContent,
  MultiSelectEmpty,
  MultiSelectGroup,
  MultiSelectInput,
  MultiSelectItem,
  MultiSelectLabel,
  MultiSelectList,
  MultiSelectTrigger,
  MultiSelectValue,
} from "@/components/motion/multi-select";

const colors = {
  design: "fill-rose-500 text-rose-500",
  engineering: "fill-sky-500 text-sky-500",
  product: "fill-amber-500 text-amber-500",
  research: "fill-cyan-500 text-cyan-500",
  marketing: "fill-emerald-500 text-emerald-500",
  operations: "fill-slate-500 text-slate-500",
};

function Option({
  value,
  children,
}: {
  value: keyof typeof colors;
  children: string;
}) {
  return (
    <MultiSelectItem value={value} textValue={children}>
      <span className="flex items-center gap-2.5">
        <Circle aria-hidden="true" className={`size-2.5 ${colors[value]}`} />
        {children}
      </span>
    </MultiSelectItem>
  );
}

export function MultiSelectPreview() {
  return (
    <div className="flex min-h-[420px] w-full items-start justify-center px-4 pt-24">
      <div className="w-full max-w-sm">
        <MultiSelect defaultValue={["design", "engineering"]}>
          <MultiSelectTrigger>
            <MultiSelectValue placeholder="Choose teams" />
            <MultiSelectInput aria-label="Search teams" />
          </MultiSelectTrigger>
          <MultiSelectContent>
            <MultiSelectList ariaLabel="Teams">
              <MultiSelectGroup>
                <MultiSelectLabel>Product teams</MultiSelectLabel>
                <Option value="design">Design</Option>
                <Option value="engineering">Engineering</Option>
                <Option value="product">Product</Option>
                <Option value="research">Research</Option>
              </MultiSelectGroup>
              <MultiSelectGroup>
                <MultiSelectLabel>Business teams</MultiSelectLabel>
                <Option value="marketing">Marketing</Option>
                <Option value="operations">Operations</Option>
              </MultiSelectGroup>
              <MultiSelectEmpty>No teams found.</MultiSelectEmpty>
            </MultiSelectList>
          </MultiSelectContent>
        </MultiSelect>
      </div>
    </div>
  );
}
```

## API Reference

### MultiSelectContent

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `side` | `"top" \| "bottom"` | `bottom` | No | Preferred side of the field to open on. Default: "bottom" |
| `align` | `"start" \| "center" \| "end"` | `start` | No | Horizontal alignment against the field. Default: "start" |
| `sideOffset` | `number` | `6` | No | Gap between the field and the panel, in px. Default: 6 |
| `avoidCollisions` | `boolean` | `true` | No | Flip to the other side when there is more room there. Default: true |
| `className` | `string` |  | No | Classes merged onto the panel element. |

### MultiSelect

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `value` | `string[]` |  | No | The selected values, for controlled use. |
| `defaultValue` | `string[]` | `[]` | No | The initial selected values when uncontrolled. Default: [] |
| `onValueChange` | `((value: string[]) => void)` |  | No | Called with the new list of values when an option is added or removed. |
| `open` | `boolean` |  | No | Whether the list is open, for controlled use. |
| `defaultOpen` | `boolean` | `false` | No | Whether the list starts open when uncontrolled. Default: false |
| `onOpenChange` | `((open: boolean) => void)` |  | No | Called with the new state when the list opens or closes. |
| `query` | `string` |  | No | The search text, for controlled use. |
| `defaultQuery` | `string` |  | No | The initial search text when uncontrolled. Default: "" |
| `onQueryChange` | `((query: string) => void)` |  | No | Called with the new text when the search input changes. |
| `filter` | `OptionFilter` | `(value, query, keywords) => { const needle = query.trim().toLocaleLowerCase(); if (!needle) return true; const haystack = [value, ...keywords].join(" ").toLocaleLowerCase(); let queryIndex = 0; for (const character of haystack) { if (character === needle[queryIndex]) queryIndex += 1; if (queryIndex === needle.length) return true; } return false; }` | No | Decides which options match the search text. |
| `disabled` | `boolean` | `false` | No | Blocks opening and changing the selection. Default: false |
| `className` | `string` |  | No | Classes merged onto the root element. |
| `labels` | `Partial<{ valuePlaceholder: string; removeValue: string; inputLabel: string; inputPlaceholder: string; listLabel: string; empty: string; }>` |  | No | Override any built-in string. `{label}` fills the option label. |

### MultiSelectEmpty

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `className` | `string` |  | No | Classes merged onto the empty message. |

### MultiSelectGroup

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `className` | `string` |  | No | Classes merged onto the group fieldset. |

### MultiSelectItem

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `value` | `string` |  | Yes | The option's value, added to or removed from the selection. |
| `textValue` | `string` |  | No | Text for search and the trigger chip when the label is not plain text. |
| `keywords` | `string[]` | `[]` | No | Extra words that match this option in search. |
| `disabled` | `boolean` | `false` | No | Keeps the option visible but not selectable. Default: false |
| `onSelect` | `((value: string) => void)` |  | No | Called with the option's value when it is clicked, before it toggles. |
| `className` | `string` |  | No | Classes merged onto the option row. |

### MultiSelectLabel

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `className` | `string` |  | No | Classes merged onto the label element. |

### MultiSelectList

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `ariaLabel` | `string` |  | No | Accessible name for the listbox. Default: "Options" |
| `className` | `string` |  | No | Classes merged onto the scrolling listbox. |

### MultiSelectSeparator

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `className` | `string` |  | No | Classes merged onto the separator line. |

### MultiSelectInput

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `ref` | `Ref<HTMLInputElement>` |  | No | Ref to the search input element. |
| `showIcon` | `boolean` | `false` | No | Shows a search icon before the input. Default: false |
| `className` | `string` |  | No | Classes merged onto the root element. |

### MultiSelectTrigger

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `className` | `string` |  | No | Classes merged onto the trigger element. |

### MultiSelectValue

| Prop | Type | Default | Required | Description |
| --- | --- | --- | --- | --- |
| `placeholder` | `ReactNode` |  | No | Shown while nothing is selected and the list is closed. Default: "Select options" |
| `className` | `string` |  | No | Classes merged onto the wrapper around the chips. |
| `chipClassName` | `string` |  | No | Classes merged onto each selected value chip. |

## About Multi Select

Multi Select is a composable searchable multi-select for React built with Framer Motion and Tailwind CSS. Chosen options appear as removable tokens inside the field that animate in and out, and the option list springs open into a collision-aware portal. Typing filters the list, grouped options are supported, and the list stays open after each pick so several values can be chosen in a row.

### When to use it

- A form needs to collect several values from a known list, such as tags, skills or team members.
- A filter bar lets people narrow results by multiple categories, statuses or labels at once.
- An invite or sharing flow picks multiple recipients from a searchable, grouped directory.

### Accessibility

MultiSelectInput has the combobox role with aria-activedescendant, and the list is a listbox marked aria-multiselectable with options that expose aria-selected. Arrow Up and Arrow Down open and move through options, Home and End jump to the ends, Enter toggles the active option, Escape closes and returns focus, and Backspace in an empty field removes the last token. Each token has a remove button labelled with the option name, and MultiSelectEmpty uses the status role. With reduced motion enabled, tokens and the panel appear without movement and the highlight jumps between rows.

### FAQ

**How do I make a multi select dropdown with tags in React?**

Compose MultiSelect with MultiSelectTrigger holding MultiSelectValue and MultiSelectInput, then MultiSelectContent with a MultiSelectList of MultiSelectItem elements. MultiSelectValue renders the chosen values as removable tokens.

**Can I control which values are selected?**

Yes. MultiSelect takes value as a string array with onValueChange, or defaultValue for uncontrolled use. The search text and open state are also controllable through query and open with their default and change props.

**Can I customize how each token looks?**

Yes. Pass a render function as the children of MultiSelectValue to receive each value and label, and use chipClassName to style the tokens. A custom filter function on MultiSelect changes how options match the query.

## React Native

A React Native version ships in beUI Native. The detail JSON has every file to copy.

```bash
npx expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-worklets
npm install uniwind tailwindcss
```

- Native detail: https://beui.dev/native/r/multi-select
- GitHub: https://github.com/starc007/beui-native/tree/main/src/components/multi-select

## Source

- Registry detail: https://beui.dev/r/multi-select
- Raw source: https://beui.dev/r/multi-select/raw
- GitHub: https://github.com/starc007/ui-components
