A switch is a control that turns one setting on or off. It is like a small light switch: its position shows whether the setting is active. For example, a website might let you turn dark mode on with a switch.
A switch usually takes effect right away, without a separate Save button. That makes it different from a checkbox in a longer form, where a person may select several options and submit them later. The words beside the switch should name the setting, such as “Email alerts.”
Use a switch when the choice changes a setting immediately. Make its current state clear so people can tell whether the feature is on or off.
