How to set up repeating items in a digest

A digest repeats one section of your newsletter for every entry. You mark that section with two markers, [entry]   and [/entry]  , in the MailPoet editor. This article shows how to place them, how to alternate item styles, and what to watch out for.

Before you begin: You need a Gravity Forms form that collects the entries you want to send out.

Tip: An AI assistant can do steps 2 to 4 for you. Duplicate a newsletter whose design you like, then ask your assistant to turn the copy into a digest source for your form. It adds the markers and merge tags, and can set up the feed too. See Connect an AI assistant over MCP.

Step 1: Create the source newsletter

The source newsletter holds your layout. Every digest is a copy of it.

  1. In your WordPress admin, go to MailPoet and click Emails.
  2. Click New Email, then choose Newsletter.
  3. Pick a design and add the parts that appear once, such as your header and footer.
  4. Click Save. You don't need to send it.

Step 2: Add the markers

  1. Open your source newsletter in the MailPoet editor.
  2. Above the content that should repeat, add a Text block and type [entry]    .
  3. Below that content, add another Text block and type [/entry]    .
  4. Click Save.

Everything between the two markers repeats once per entry. Content above and below them, such as your header and footer, appears once.

Header
[entry]
Item (title, description, link)
[/entry]
Footer
A MailPoet Newsletter with `[entry]` blocks delimiting the item.

Step 3: Fill the item with entry values

Inside the item, use Gravity Forms merge tags to show each entry's values. For example, {Title:1}     shows the value of field 1. Each copy of the item gets the values of its own entry.

Step 4: Connect the newsletter to your form

  1. Open your form, go to Settings, and click MailPoet Compose.
  2. Click Add New.
  3. Under Source, choose Existing newsletter, then select your source newsletter under Newsletter.
  4. Fill in the Subject and Send to list, and click Save Settings.

Your digest is ready to generate.

Optional: Alternate item styles

Add an [else]     marker between two styles to make entries take turns:

[entry]
Item style A
[else]
Item style B
[/entry]

Entry one uses style A, entry two uses style B, entry three uses style A again, and so on.

Optional: Split entries over two sections

To give the first few entries a different layout from the rest, see Split digest entries over sections with limit and offset.

Things to watch out for

  • Each marker needs its own row. Put every marker in its own text block, in a row with nothing else in it. A marker next to other content, or two markers in one row, stops the draft from generating.
  • Build the source as a newsletter. A MailPoet template is locked once it's in use, so you can't change its markers later.