---
metadata:
  - name: generator
    content: Diplodoc Platform v5.50.3
alternate:
  - https://divkit.tech/docs/en/concepts/divs/2/div-action-set-state.md
  - https://divkit.tech/docs/ru/concepts/divs/2/div-action-set-state.md
---
> **Documentation Index:** Fetch the complete configuration index at https://divkit.tech/docs/en/llms.txt

# div-action-set-state
Applies a new appearance to the content in `div-state'.

## Parameters
| Parameters | Description |
| --- | --- |
| `state_id` | <p>**string**</p><p>Required parameter.</p><p>The path of the state inside `state` that needs to be activated. Set in the format `div_data_state_id/id/state_id'. Can be hierarchical: `div_data_state_id/id_1/state_id_1/../id_n/state_id_n`. Consists of:<li>`div_data_state_id` — the numeric value of the `state_id` of the `state` object in `data`</li><li>'id` — the `id` value of the `state` object</li><li>`state_id` — the `state_id` value of the `state` object in `state`</li></p><p>Available platforms: Android, iOS, web.</p> |
| `type` | <p>**string**</p><p>Required parameter.</p><p>The value must always be `set_state`.</p><p>Available platforms: Android, iOS, web.</p> |
| `temporary` | <p>**bool**</p><p>Indicates a state change:<li>`true` — the change is temporary and will switch to the original one (default value) when the element is recreated</li><li>`false` — the change is permanent</li></p><p>Default value: `true`.</p><p>Available platforms: Android, iOS.</p> |

<details>
<summary>JSON</summary>

```json
{
  type*: "set_state",
  state_id*: "string",
  temporary: "bool"
}
```
</details>
