Combobox

Search a long list and pick one value, or several.

Fig. 1 Search for a timezone, or pick several topics as chips.

When to use it

Use Combobox when the list is too long to scan: countries, people, labels, repositories. Typing narrows it to a few matches.

Turn on multiple to collect several values as chips, such as tags or teammates to invite.

Radio Group

One choice, every option visible.

Visibility

Only you can see this project.

Everyone on the Design team can view and edit.

Anyone in the workspace can find it.

Two to five options worth comparing.

Select

A short list, one value.

Selected: Personal workspace.

A role, a region, or a sort order.

ComboboxThis page

A long list, searched.

Countries, people, and tags.

Fig. 2 Three ways to choose one value. Pick by how many options there are and whether people should see them all.

How it behaves

Pass items to Combobox and render them with ComboboxList; Base UI filters them as you type. Use value/onValueChange or defaultValue, and multiple for several values.

ComboboxInput is an Input Group with a chevron trigger; showClear adds a clear button. For many values, use ComboboxChips with ComboboxValue, ComboboxChip, and ComboboxChipsInput, and anchor the popup to the chips with useComboboxAnchor.

Like Select, a leading checkmark marks the selected value. Group items as { value, items } with ComboboxGroup, ComboboxLabel, and ComboboxCollection.

Use Select for short fixed lists and Combobox once people need to search. Label the input; arrow keys move the highlight, Enter chooses it, and Escape closes the list.

Build it

Add it with the shadcn CLI:

Terminal

A complete example. Change the values to fit your product:

combobox-example.tsx

The full source is yours to edit once installed:

combobox.tsx