Skip to content

FormControlLabel API

API reference docs for the React FormControlLabel component. Learn about the props, CSS, and other APIs of this exported module.

Component demos

Import

import FormControlLabel from '@mui/material/FormControlLabel';
// or
import { FormControlLabel } from '@mui/material';
Learn about the difference by reading this guide on minimizing bundle size.

Drop-in replacement of the Radio, Switch and Checkbox component. Use this component if you want to display an extra label.

Props

Props of the native component are also available.

controlRequired

A control element. For instance, it can be a Radio, a Switch or a Checkbox.

Type:element


checked

If true, the component appears selected.

Type:bool


classes

Override or extend the styles applied to the component.

See CSS API below for more details.

Type:object


componentsProps

The props used for each slot inside.

Type:{ typography?: object }

Default:{}


disabled

If true, the control is disabled.

Type:bool


disableTypography

If true, the label is rendered as it is passed without an additional typography node.

Type:bool


inputRef

Pass a ref to the input element.

Type:ref


label

A text or an element to be used in an enclosing label element.

Type:node


labelPlacement

The position of the label.

Type:'bottom'
| 'end'
| 'start'
| 'top'

Default:'end'


onChange

Callback fired when the state is changed.

Type:func

Signature:
function(event: React.SyntheticEvent) => void
  • event The event source of the callback. You can pull out the new checked state by accessing event.target.checked (boolean).

required

If true, the label will indicate that the input is required.

Type:bool


slotProps

The props used for each slot inside.

Type:{ typography?: object }

Default:{}


sx

The system prop that allows defining system overrides as well as additional CSS styles.

See the `sx` page for more details.

Type:Array<func
| object
| bool>
| func
| object


value

The value of the component.

Type:any


The ref is forwarded to the root element.

Theme default props

You can use MuiFormControlLabel to change the default props of this component with the theme.


CSS classes

These class names are useful for styling with CSS. They are applied to the component's slots when specific states are triggered.

.Mui-disabledSTATE

State class applied to the root element if disabled={true}.


.Mui-errorSTATE

State class applied to the root element if error={true}.


.Mui-requiredSTATE

State class applied to the root element if required={true}.


.MuiFormControlLabel-asterisk

Styles applied to the asterisk element.

Rule name:asterisk


.MuiFormControlLabel-label

Styles applied to the label's Typography component.

Rule name:label


.MuiFormControlLabel-labelPlacementBottom

Styles applied to the root element if labelPlacement="bottom".

Rule name:labelPlacementBottom


.MuiFormControlLabel-labelPlacementStart

Styles applied to the root element if labelPlacement="start".

Rule name:labelPlacementStart


.MuiFormControlLabel-labelPlacementTop

Styles applied to the root element if labelPlacement="top".

Rule name:labelPlacementTop


.MuiFormControlLabel-root

Styles applied to the root element.

Rule name:root



You can override the style of the component using one of these customization options:

Edit this page

Was this page helpful?


FormControlFormGroup

Blog

Store