Radio

One choice from a set.

Base UI RadioBase UI Radio GroupSource

Radio group

Put each Radio.Root in a RadioGroup, and give each radio a value. The user can select one value.

Controlled

Pass value and onValueChange to RadioGroup to keep the value in your component.

Billing period: annual

Disabled

Set disabled on a Radio.Root to disable one option, or on RadioGroup to disable all options. Add text-muted to the label yourself.

One option
Whole group

Usage

These are defaults, not laws. Break one when you have a good reason, or when it makes the design more cohesive or more interesting.

  • Choose the input from the number of options and what the user picks.
    ComponentUse it for
    RadioOne choice from 2 or 3 options that stay visible.
    SelectOne choice from 4 to about 10 options, or fewer options when space is tight.
    ComboboxOne or more choices from a long list, with typing to filter.
    AutocompleteFree text, with suggestions that the user can ignore.
    ChoiceboxA choice where each option needs a description, such as a plan.
    CheckboxAn on or off value in a form that the user submits.
    SwitchA setting that applies at once.
  • Name the group with aria-label or aria-labelledby, and put each radio and its text in a <label>.

API

Props that the library adds. Every part also takes all the Base UI props.

Radio.Indicator

PropTypeDefaultDescription
keepMountedbooleantrueKeeps the dot in the DOM when the radio is not selected. The Base UI default is false.