Flowbite Svelte: v0.46.14
Svelte: v5.0.0-next.179
SvelteKit: v2.5.18
Vite: v5.3.3

Checkbox

The checkbox component can be used to receive one or more selected options from the user in the form of a square box available in multiple styles, sizes, colors, and variants.

Checkbox examples

Use this default example of a checbkox element in a checked, unchecked and indeterminate state.

Disabled state

This example can be used for the disabled state of the checkbox component by applying the disabled attribute to the input element.

Alternative syntax

If you need separate control over the label and the checkbox you can use the verbose syntax, but then you need to take care about aligning manually.
NOT WORKING

Checkbox with a link

Use this example if you want to add an anchor link inside the label of the checkbox component.

Helper text

Get started with this example if you want to add a secondary helper text for the checkbox component.

For orders shipped from $25 in books or $29 in other categories

Bordered

Use this example of a checkbox inside a card element to enable a larger area of clicking activation.

Checkbox list group

Use this example to show a list of checkbox items grouped inside a card.

Technology

Horizontal list group

Use this example to show a list of checkbox items inside a card horizontally.

Identification

Checkbox dropdown

Use this example to show a list of checkbox items inside a dropdown menu.

Inline layout

You can align the checkbox elements horizontally by using a wrapper tag and applying the flex class.
You can use the property `inline` as the alternative.

Colors

CheckboxButton

The special case component - `CheckboxButton` - is the `Checkbox` with the [Button](/docs/components/buttons) look and feel. I can be used as standalone element or be wrapped inside [ButtonGroup](/docs/components/button-group). This component accepts all props from the [Button](/docs/components/buttons) for styling and `Checkbox` for behaviour.

Advanced layout

Use this example of an advanced layout of checkbox elements where the label parent element can be styled when the checkbox is checked.

Choose technology:

Group variable

Group: 2,3