Radio Group

A radio group allows a user to select a single item from a list of mutually exclusive options.

React frameworks
<RadioGroup defaultValue="nextjs">
  <Label>React frameworks</Label>
  <FieldGroup>
    <Radio value="nextjs">
      <RadioControl />
      <Label>Next.js</Label>
    </Radio>
    <Radio value="remix">
      <RadioControl />
      <Label>Remix</Label>
    </Radio>
    <Radio value="gatsby">
      <RadioControl />
      <Label>Gatsby</Label>
    </Radio>
  </FieldGroup>
</RadioGroup>

Installation

npx shadcn@latest add @dotui/radio-group

Usage

Use radio group to allow users to select a single option from a short list of related options.

import { Radio, RadioControl, RadioGroup } from "@/components/ui/radio-group";
import { FieldGroup, Label } from "@/components/ui/field";
<RadioGroup defaultValue="nextjs">
	<Label>React frameworks</Label>
	<FieldGroup>
		<Radio value="nextjs">
			<RadioControl />
			<Label>Next.js</Label>
		</Radio>
		<Radio value="remix">
			<RadioControl />
			<Label>Remix</Label>
		</Radio>
	</FieldGroup>
</RadioGroup>

Playground

Use the controls below to experiment with different radio group props and see the live preview and code update.

Select frameworks
orientation
<RadioGroup defaultValue="react">
  <Label>Select frameworks</Label>
  <FieldGroup>
    <Radio value="react">
      <RadioControl />
      <Label>React</Label>
    </Radio>
    <Radio value="vue">
      <RadioControl />
      <Label>Vue</Label>
    </Radio>
    <Radio value="angular">
      <RadioControl />
      <Label>Angular</Label>
    </Radio>
  </FieldGroup>
</RadioGroup>

Examples

Default

React frameworks

With Description

React frameworksYou can pick one framework.

Invalid

React frameworks
Please select a framework.

Disabled

React frameworks

ReadOnly

React frameworks

Required

React frameworks

Cards

React frameworks

API Reference

RadioGroup

A radio group allows a user to select a single item from a list of mutually exclusive options.

PropType
ReactNode | function
boolean
boolean
Orientation
DOMRenderFunction<"div", RadioGroupRenderProps>
null | string
null | string
function

Radio

A radio represents an individual option within a radio group.

PropType
ReactNode | function
RefObject<HTMLInputElement | null>
boolean
DOMRenderFunction<"div", RadioFieldRenderProps>

RadioControl

The clickable radio control, including the indicator and optional label content.

PropType
ReactNode | function
DOMRenderFunction<"label", RadioButtonRenderProps>

Last updated on 5/22/2026