> ## Documentation Index
> Fetch the complete documentation index at: https://loops.so/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Arrays

> Arrays let you add repeatable content blocks to transactional emails, populated at send time via data variables.

Arrays are a way to add repeatable sections to an email allowing you to add a dynamic list of items, like products.

You can display up to 100 items in each array block.

> [!NOTE]
>
> Arrays are currently supported in transactional emails.

## Adding arrays

You can add array blocks to your email by using the button in the editor toolbar or typing `/` and selecting **Array**.

![Add an array](https://mintcdn.com/loops/QNkh2P3cmoyoSmv7/images/array-button.png?fit=max\&auto=format\&n=QNkh2P3cmoyoSmv7\&q=85\&s=56794615ab6bc3bdcb05a4cd8cbd721b)

Arrays are assigned a data variable name (default is `items`) which can be changed in the editor panel in the **Array** section.

![Editor panel with array section](https://mintcdn.com/loops/QNkh2P3cmoyoSmv7/images/array-sidebar.png?fit=max\&auto=format\&n=QNkh2P3cmoyoSmv7\&q=85\&s=1fa61002fd1dc6bd4bca37a844d82806)

## Adding content to arrays

Once the array block is in your email, you can add content inside, which will be repeated for each item in the array.

For example, if you have an array of products and you want to show a name and a description for each product, you can add a heading and a text block inside the array block.

![Array block with example product inside](https://mintcdn.com/loops/QNkh2P3cmoyoSmv7/images/array-content.png?fit=max\&auto=format\&n=QNkh2P3cmoyoSmv7\&q=85\&s=3410f0ba428c42c771f0a1fca78bad51)

## Adding dynamic content

You can add dynamic content to array blocks by inserting [data variables](https://loops.so/docs/transactional.md#add-data-variables). These data variables can then be populated with data when you [send your email](https://loops.so/docs/transactional.md#send-your-email).

You can add data variables by using the button above the editor, typing `{`, or typing `/` and selecting **Data variable**.

![Add a data variable](https://mintcdn.com/loops/QNkh2P3cmoyoSmv7/images/array-variables.png?fit=max\&auto=format\&n=QNkh2P3cmoyoSmv7\&q=85\&s=f1c2c66db8f234114658f25305d9dbc6)

By default, data variables you add will be available within the array block only. You can change variable tags inside array blocks to be "global" by changing the **Array item** option in the right sidebar to **No**.

![Global toggle](https://mintcdn.com/loops/QNkh2P3cmoyoSmv7/images/array-global-variable.png?fit=max\&auto=format\&n=QNkh2P3cmoyoSmv7\&q=85\&s=6c39c84b3e639faddf392df15a111ce7)

## Previewing arrays

You can preview how multiple items will look in your email by using the `+` and `-` buttons in the **Preview** section of the editor sidebar. These buttons allow you to see how the array will look in your email with different numbers of items.

![Preview items](https://mintcdn.com/loops/QNkh2P3cmoyoSmv7/images/array-preview.png?fit=max\&auto=format\&n=QNkh2P3cmoyoSmv7\&q=85\&s=d88a39c4599359e31402c96a841b11a6)


## Related topics

- [Uploading a custom email](https://loops.so/docs/creating-emails/uploading-custom-email.md)
- [Transactional email](https://loops.so/docs/transactional.md)
- [Transactional email API examples](https://loops.so/docs/api-reference/examples/transactional-emails.md)
- [The editor](https://loops.so/docs/creating-emails/editor.md)
- [Attachments](https://loops.so/docs/transactional/attachments.md)
