---
title: "switch · RUAL Documentation"
description: "Returns mutations based on the given expression."
canonical: https://docs.rual.nl/block-types/mutations/mutations_switch
language: en
---

# switch

This block is part of the [`mutations`](https://docs.rual.nl/block-types/mutations) group and was last modified in core [`v12.0.4`](https://docs.rual.nl/core-versions/120004).

Returns mutations based on the given expression.

- expression required `value` The expression to evaluate.

- default `mutations` The default statement to be executed.

- output `mutations` Returns the mutations matching the expression.

- match `condition` Returns true if a match was found.

A typical wiring for [switch](https://docs.rual.nl/block-types/mutations/mutations_switch): the `mutations` out pin feeds [get at index](https://docs.rual.nl/block-types/mutations/mutations_get_at_index).

![Studio canvas example for the switch block: typical wiring for switch.](https://docs.rual.nl/canvas-examples/mutations_switch.png)

### Version history

Introduced in [`v12.0.4`](https://docs.rual.nl/core-versions/120004).
