--- title: "Create a Personalization Rule" slug: "create-a-personalization-rule" description: "Step by step: create a personalization rule in the Mapp Engage Personalization Builder with conditions, blocks, and content, then use or save it." status: "update" updated: 2026-11-04T10:58:34Z published: 2026-11-04T10:58:34Z canonical: "docs.mapp.com/create-a-personalization-rule" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.mapp.com/llms.txt > Use this file to discover all available pages before exploring further. # Create a Personalization Rule ## Goal Create a personalization rule in the **Personalization Builder**: define conditions, structure `InsertIf` and `InsertElse` blocks, add content, and use or save the rule. --- ## Background Information - A personalization rule always contains at least one `InsertIf` block with the conditions that must be met for this block to apply. - A rule can include additional `InsertElse` blocks, nested blocks, and a default block. - A rule can contain its own content, for example a complete greeting. - When you insert a rule into a message, its code is copied into the message. Changes you make in the message do not change the saved rule. For the concepts, see [Personalization Rules](/v1/docs/personalization-rules-insertif-insertelse). For all elements of the Builder, see [Personalization Builder: Create and Edit](/v1/docs/personalization-builder-create-and-edit). --- ## Procedure ### 1 Open the Personalization Builder You can open the Personalization Builder during message creation or from the personalization overview. #### During message creation 1. In the message, place the cursor where the personalization should appear, for example in the subject line. In the CMS, place the cursor inside a paragraph of a text field. 2. Click **Personalization**. 3. Click **New**. The Personalization Builder opens in Edit Mode for the first `InsertIf` block. #### From the personalization overview 1. Go to *Audience > Segmentation > Personalization*. 2. Click **Create**. The Personalization Builder opens in Edit Mode for the first `InsertIf` block. ### 2 Create conditions Conditions define when a block applies. 1. Click the plus symbol. The Condition Builder opens. 2. In the first input field, select the attribute. 3. In the list field in the center, select the relation, for example **Equals** or **greater than**. The available relations depend on the data type of the attribute. 4. In the second input field, enter the value. For enumerated attributes, select the value from the list. To compare the attribute with another attribute, select **Compare two attributes** and select the second attribute. 5. Click **Add**. The condition is added to the block. 6. To add more conditions, open the menu (▼) and select **Add condition**. 7. In **Conditions to be matched**, select **all** if every condition must be true, or **one** if at least one condition must be true. 8. To group conditions, select the checkbox at the end of each condition and click **Group**. Grouped conditions are shown in parentheses. Click a parenthesis to expand or collapse the group. With groups, you can combine conditions where all must match with conditions where only one must match, all within one block. #### Example: Grouping conditions You want to insert a paragraph only for male recipients over 18 and for female recipients whose hobby is football. You create four conditions and group them as follows: - Group 1: "Gender equals male" and "age is greater than 18", with **all**. - Group 2: "Gender equals female" and "hobby equals football", with **all**. - For the two groups, select **one**, so that the paragraph is inserted if one of the groups matches. ### 3 Structure the rule Use the structure to define alternative blocks and nested checks within one rule, for example a greeting with several fallback options. 1. Click **Structure**. The Structure view opens. 2. To add an `InsertElse` block, click the ![](https://cdn.document360.io/554b9b98-6720-4d8b-9919-c7b203d72648/Images/Documentation/image-JD9LDJN9.png) button. 3. To define the conditions of the `InsertElse` block, open its menu (▼) and select **Edit**. Create the conditions as described in step 2. 4. To create a nested block, open the menu of the block and select **Add Nested InsertIf**. 5. To add a default block, open the menu and select **Add Default**. Default blocks have no conditions. They apply if none of the other blocks in the rule match. #### Example: Nested InsertIf for a greeting You want a greeting that first checks whether a last name is stored. Within this block, you then differentiate by gender. - Each branch of the greeting is a separate block. - The block for contacts with a last name contains nested blocks for women, men, and unknown gender. - Nested blocks usually need less code than separate blocks with very complex conditions. ### 4 Add content to the blocks After defining the structure and conditions, add the content that should appear for each block. 1. Open the menu of the block and select **Add Content**. A content block is added. 2. Click the pencil icon of the content block. The **Add Content** dialog opens. 3. Enter the text, including HTML formatting if needed. 4. (Optional) To insert an attribute value, select the attribute in **Attributes** and click the insert icon. 5. Click **Save**. 6. (Optional) Open the menu of the block, select **Edit Block Name**, and enter a descriptive name. Block names are useful in complex structures. The name is shown in the structure, becomes the ID of the block in the code, and appears in the email message statistics. ### 5 Use or save the rule Before you use the rule, test it in two stages: 1. In the Builder, click **Preview**. The preview validates the rule. Enter the email address of a test contact and click **Update**. Repeat this with test contacts whose attribute values match each branch of the rule, including a contact with empty values. See [Personalization Builder: Preview](/v1/docs/preview-personalization). 2. After you insert the rule, preview the message with different contacts. See [Message Preview (Email)](/v1/docs/email-message-preview). To see the code that is inserted into the message, click **Code**. #### Use the rule without saving 1. Click **Use**. You return to the message. 2. Insert the rule at the position where it should appear, for example by right-clicking the position in the editor. If you opened the Builder from the personalization overview, you must save the rule before you can use it in messages. #### Save the rule for later use 1. Enter a **Name**. 2. Enter a **Description**. A description is highly recommended, because personalization names are not unique. 3. Click **Save**. You can then search for the rule by name in the personalization dialog of any message and reuse it. ## Related - [Personalization Builder: Create and Edit](/personalization-builder-create-and-edit.md) - [Personalization Builder: Preview](/preview-personalization.md)