Skip to main content

What are toggles?

Toggles are an interface component that let users enable or disable a feature. Think of them as a light switch. A user can turn on a feature knowing that in the future if they’d like, they can easily turn it off

When to use a toggle.

You’d want to use a toggle when your users need to make a single yes/no decision quickly. Sometimes it’s easy to confuse whether to use a checkbox versus a toggle. Both are valid options for most functionality but each has separate connotations.

A toggle deliberately makes the user choose between ‘yes I want this functionality on or off’ where as a checkbox could imply the option for selecting multiple choices at once. So while both could work I say use the component that best fits your use case.

Styling Toggles

There are a few things to consider when styling toggles

What are the main states you want the user to see?

The obvious ones are toggled on and toggled off. However, what happens when the feature isn’t enabled for a specific user role? Usually, I’d say remove the option altogether since you probably don’t want the user seeing functionality they’d never be able to interact with.

In some use cases, you may want to show a disabled toggle to signal to the User that this is an option that could be available to them. For instance, if a user is using a software trial but you want them to purchase it. You may show some exciting or useful functionality as disabled to entice them to pay for it.

Toggled On
Toggled Off

How to improve contextual awareness through micro-interactions

It’s easy to create a toggle with two or three different states. If you want to add a little polish or give the user a bit more feedback when they’re interacting with your UI you may consider animating your toggle.

The animation is going to depend on how you construct your toggle. The basics are adding an effect on hover and activation. From there, you can add little things like shadows, confetti, or changes to other elements on your page (think activating dark mode).

These micro-interactions are important because they’re a visual reminder to the user that the software is reacting to their movements and that what they’re about to do will actually modify their remaining experience.

Get started designing

I created a free toggle pack for Adobe XD. Each toggle in this set is designed with different states and interactions built in. Please feel free to use this wherever you’d like!