Check box

Flexible checkbox components with support for individual checkboxes and checkbox groups. Click the code examples to copy them.

Basic Checkbox

A simple uncontrolled checkbox component

Controlled Checkbox

A controlled checkbox with state management and onChange handler

Disabled Checkbox

A checkbox in disabled state

Checkbox Group (Horizontal)

Multiple checkboxes arranged horizontally with group management

Checkbox Group (Vertical)

Multiple checkboxes arranged vertically (default layout)

Props Reference

PropTypeDescription
namestringInput name attribute
valuestringInput value attribute
labelstringLabel text displayed next to checkbox
checkedbooleanControlled checked state
defaultCheckedbooleanInitial checked state for uncontrolled checkbox
disabledbooleanDisables the checkbox
onChangefunctionCallback when checkbox state changes
optionsarray(CheckBoxGroup only) Array of checkbox options
valueClassNamestring(CheckBoxGroup only) Custom styles for options container