How to Add A Close Link or Button to OptinMonster

OptinMonster makes it easy to add a close link or button to popup type campaigns.

In this article, you’ll learn how to add a close link or button in OptinMonster.

Before You Start

Here are some things to know before you begin:

  • You can add a close icon to any popup type campaign (Lightbox, Fullscreen, Floating Bar, Slide-In). They cannot be added to Inline campaigns.

Close Button

You can enable and disable the default close button for your campaign. Once enabled, you can then customize the size, color, and other settings.

To add a close button, follow these steps:

  1. In the campaign builder, navigate to Optin Settings > Close Button in the sidebar.
    Close Button Panel
  2. Next, toggle the Display a close button? option on.
    Enable Display Close Button
  3. You can now customize the appearance of the close button with the options available in the sidebar.
  4. When you’re finished, click Save.

Button Element

You can also use a button element to close the campaign. This can be added in addition to the close button outlined in the previous section, or on its own.

To add a button element to close the campaign, follow these steps:

  1. In the campaign builder, select the + Add Blocks button.
    Add block to CM Commerce Popup Demo
  2. Next, select and drag a Button element into your campaign.
  3. You’ll want to edit the Button element’s Action by selecting the Action tab in the sidebar.
    Button Close Action
  4. From the Button Click Action dropdown select Close the campaign.
  5. (Optional) Returning to the Button tab in the sidebar you can customize the appearance of the Button element.
  6. When you’re finished, click Save.

HTML Close Link

If you’d prefer to use HTML you can also add a close link with this approach.

To add an HTML close link to your campaign, follow these steps:

    1. In the campaign builder, select the + Add Blocks button.
      Add block to CM Commerce Popup Demo
    2. Next, select and drag an HTML element into your campaign.
    3. You can now enter your custom HTML close link into the provided field. Your close link will need to include the class om-trigger-close, for example:
      <a href="#" class="om-trigger-close">Close Campaign</a>
    4. When you’re finished, click Save.