Skip to content
Component

Switch

On/off toggle with a thumb that rolls across the track.

States

Disabled

disabled dims the track and blocks input, on or off.

Tones

tone colors the track and thumb once the switch is on.

Controlled

Own the on/off state with checked and onCheckedChange.

Off

API reference

labelNone
React.ReactNode

Text beside the switch. Clicking it toggles. Also the control's accessible name.

tone"default"
ComponentTone

Track/thumb color once on. Default "default".

Also accepts everything from React.ComponentPropsWithoutRef<typeof import("@base-ui/react/switch").Switch.Root>.

Coding agents read this reference, with its examples, from the version your project has installed, through the Fuji UI MCP server. Set up your agent