---
title: Set checkbox
description: "Set a checkbox to a target state, clicking only when the current state differs. Legacy step, prefer Click on modern checkboxes."
lastUpdated: "2026-09-23"
---

> **For AI agents:** the complete documentation index is at [llms.txt](/llms.txt). Append `.md` to any page URL for its markdown version.

<Danger>
  **Deprecated.** This step no longer appears in the step palette. Existing tests that use it keep running. For new tests, use [Click](/tests/actions/web/click) on the checkbox. A click toggles the state instead of setting it, so verify the result with [Verify element](/tests/actions/web/verifyelement) when it matters.
</Danger>

Set a checkbox to a target state. The step only clicks when the current state differs from the requested one, so it is safe to repeat.

## Parameters

| Parameter | Required | Description |
| ----------- | ---------- | ------------- |
| Target element | Yes, unless a manual selector is set | Natural-language description of the checkbox. |
| Manual selector | No | XPath or CSS selector, used when AI is disabled or as the saved selector. |
| Set as checked | No | The target state. Default: off (unchecked). |
| AI usage | No | `inherit` (default, follows the test strategy), `smart`, or `always`. |
| Ignore error on this step | No | The run continues with the next step if this one fails. Default: off. |

## Results and metrics

- **Timing**: start, end, and duration (in seconds) recorded in the step result.
- **Status**: success, warning, or failed, with the error message on failure.
- **Screenshot**: captured after the step runs.

## What's next?

<Columns cols={2}>
  <Card title="Click" icon="arrow-pointer" href="/tests/actions/web/click">

    The current way to toggle checkboxes

</Card>
  <Card title="Verify element" icon="eye" href="/tests/actions/web/verifyelement">

    Confirm the checkbox ended up in the right state

</Card>
</Columns>
