---
title: "Repeater"
description: "Add Repeater control to your custom blocks for WordPress using the Lazy Blocks plugin."
url: "https://www.lazyblocks.com/docs/blocks-controls/repeater/"
lastUpdated: 2026-09-09
source: "blocks-controls/repeater.mdx"
---
# Repeater

Repeater control lets you create dynamic groups of controls that users can add multiple times. Perfect for creating lists, slides, or any repeatable content structure.

  All controls except Inner Blocks can be used inside a repeater. This lets you
  create flexible and complex data structures.

## Control Settings

- **Row Label** (`rows_label`) - text on each row header, `Row {{#}}` when left empty. Supports dynamic values:
  - `{{#}}` - the row number, counting from 1
  - `{{control_name}}` - the value of an inner control
  - `{{control_name.url}}` - one key of an object value, such as an Image control. `alt`, `url`, `title`, `caption`, `description`, `id` and `link` are replaced
- **Add Button Label** (`rows_add_button_label`) - text on the add button, `+ Add Row` when left empty
- **Minimum Rows** (`rows_min`) - rows the control creates by itself. The remove button disappears once the count is down to this number
- **Maximum Rows** (`rows_max`) - the count at which the add button is disabled
- **Collapsible Rows** (`rows_collapsible`) - collapse rows into their headers, on by default
- **Collapsed by Default** (`rows_collapsed`) - start with every row collapsed, on by default. This setting only appears while Collapsible Rows is on

With Collapsible Rows on, opening a row closes the one that was open, so a single row is expanded at a time. Turning Collapsed by Default off opens every row until the first header is clicked.

## Usage Examples

### Basic List

```php title="PHP" /$attributes['control_name']/
<ul class="items-list">
  <?php foreach( $attributes['control_name'] as $item ): ?>
    <li>
      <?php echo esc_html( $item['title'] ); ?>
      <p><?php echo esc_html( $item['description'] ); ?></p>
    </li>
  <?php endforeach; ?>
</ul>
```

```hbs title="Handlebars" /control_name/
<ul class="items-list">
  {{#each control_name}}
    <li>
      {{title}}
      <p>{{description}}</p>
    </li>
  {{/each}}
</ul>
```

### Post Meta

```php title="Post Meta" /get_lzb_meta( 'control_meta_name' )/
<?php
$items = get_lzb_meta( 'control_meta_name' );

if ( $items ) : ?>
  <ul class="items-list">
    <?php foreach ( $items as $item ) : ?>
      <li>
        <?php echo esc_html( $item['title'] ); ?>
        <p><?php echo esc_html( $item['description'] ); ?></p>
      </li>
    <?php endforeach; ?>
  </ul>
<?php endif; ?>
```

## Nested Repeaters

  Nested repeaters (repeater inside repeater) are not supported and may cause
  unexpected behavior. This is a technical limitation that we're aware of.

Instead of nested repeaters, consider these alternatives:

- Use separate repeaters
- Split content into multiple blocks
- Use custom controls for specific use cases

Use meaningful row labels with dynamic values to help users identify content: `Slide {{#}}: {{title}}`

## Documentation Index
> Fetch the complete documentation index at: https://www.lazyblocks.com/llms.txt
> Fetch every page in a single file at: https://www.lazyblocks.com/llms-full.txt
