How to Install and Use the MailerLite Addon With WPForms

Would you like to know how to use MailerLite with WPForms? With the MailerLite addon, you can easily send leads from your forms to the MailerLite dashboard.

In this tutorial, we’ll show you how to install and use the MailerLite addon for WPForms.

  1. Installing the MailerLite Addon
  2. Setting Up MailerLite Integration
  3. Using MailerLite With Your Forms

Requirements: You need a Plus or higher license to use MailerLite integration.


1. Installing the MailerLite Addon

First, ensure you’ve installed and activated WPForms on your WordPress site. Once you’ve verified your license, you can install and activate the MailerLite addon.

2. Setting Up MailerLite Integration

Once you’ve got MailerLite installed and activated, it’s time to connect your site. To do this, you will need an API key.

Obtaining an API Key

If you have an existing API key, you can skip this section. Otherwise, open the MailerLite dashboard and click on Integrations to obtain your key.

Integrations in MailerLite dashboard

Under API in the MailerLite API section, click Use to open the token generation screen.

MailerLite dashboard use API

Next, click on Generate new token to bring up the Create new API token dialog.

Generate new token

Click on Create token to generate a new API token in this dialog.

MailerLite dashboard create token

MailerLite will generate an API key for you, which you can copy to your clipboard by clicking the Copy button.

MailerLite dashboard API token

You can also click on the Download button to download and save the API key.

MailerLite download API token

Once you’ve copied your API key, you can close the dialog. We highly recommend downloading and saving a copy of the API key.

Close the API dialog

Note: You won’t be able to reaccess the token once you’ve closed this popup. We recommend saving a copy somewhere secure.

If you lose your API token and need to connect again, you’ll need to generate a new token. You can have multiple tokens for the same account.

Managing Connections in WPForms

Now that you’ve obtained your API key, you can continue to set up MailerLite integration on your WordPress site.

To do this, go to WPForms » Settings and click on the Integrations tab.

WPForms integrations

Click on MailerLite to reveal the account details for this integration.

Next, click Add New Account, and add your account details, including the MailerLite API Key and MailerLite Account Nickname.

Add new MailerLite account

You can use anything you like for your Account Nickname, but the API key must match what you have in your MailerLite account. If you don’t provide an Account Nickname, WPForms will use your MailerLite account name.

To ensure this, paste the API key you copied earlier, where it says MailerLite API Key. Now, give your connection a name and click Connect to MailerLite.

Click Connect to MailerLite

Adding Additional Connections

If you would like to add additional connections, click on Add New Account and add a new MailerLite API key and nickname.

Adding additional connections

This will allow you to have as many connections for MailerLite as you need, so long as each has a unique API key and nickname.

Note: Although you can generate multiple API keys for the same MailerLite account, WPForms counts each as a unique connection.

If you need to remove a connection, click Disconnect.

Remove MailerLite account connection

3. Using MailerLite With Your Forms

Now that you’ve connected MailerLite to your site, you can easily use it with any of your forms. For example, we will create a new form and add MailerLite integration using one of the connections we made earlier.

Note: Sending data to MailerLite occurs in the background after the form is submitted, so actions may not appear immediately in your MailerLite dashboard.

Adding MailerLite Integration to a Form

To get started, go to WPForms » Add New.

add new form

For this example, we’ll use the Simple Contact Form template.

Selecting the Simple Contact Form template

Next, click on the Marketing tab and choose MailerLite from the list.

MailerLite in marketing tab

To choose a connection, click Add New Connection on the upper right of the interface.

Add a new MailerLite connection to your form

This will open a dialog allowing you to name your new connection. You can choose any name you like. Once you’ve selected a name, click OK to move on to the next step.

Confirm connection name

Now you’ll be able to choose any of the API connections you created earlier.

Select MailerLite API connection

Note: You can have as many connections as you need. Just set up each connection separately. Additional connections can use any of the accounts you’ve added under WPForms » Settings » Integrations.

Choosing an Action to Perform

Under Action To Perform, you can select from three options:

Choosing an action perform

Different configurations are available under each of these options. We’ve described the three options in more detail below.

Subscribe

This action will add a new subscriber upon form submission. When selected, it’ll allow you to choose a Type and any Groups you’ve created in MailerLite.

Type

Selecting a type

There are three subscription types you can choose from:

  • Active
  • Unsubscribed
  • Unconfirmed

These correspond with the subscription types found in MailerLite. When users submit a form with the Subscribe action selected, their subscription details will be updated in your MailerLite subscriptions. For example, if you choose Active, the user will be marked as Active in MailerLite.

Groups

Selecting groups in MailerLite

By using this setting, you can add or remove subscribers to or from any of the groups you have available in MailerLite.

Mapping WPForms Fields to MailerLite Custom Fields

When the Subscribe action is selected, you can map any of your form’s Field Values to MailerLite custom fields.

Map MailerLite and WPForms fields

Unsubscribe

This action will remove a contact from your MailerLite subscriber groups without deleting their information altogether. If you want to remove a subscriber, you should choose the Delete action.

Unsubscribe with groups selected

Delete

This action completely removes a contact from your subscriber list. No other options are required when this action is selected.

Delete action selected

Choosing an Email Field

Regardless of which of the above actions you choose, you will need to set an Email field. The MailerLite addon will only pull emails from fields of the type Email.

Choose an email field

Choosing Groups

When the Subscribe and Unsubscribe actions are selected, you can choose from any groups that already exist in your MailerLite subscriptions.

Some groups selected

Enabling Conditional Logic

You can enable conditional logic when setting up MailerLite connections. Just click on Enable Conditional Logic to activate it.

Enable conditional logic

You can then set any rules that you’d like, according to the WPForms conditional logic system.

Editing conditional logic in MailerLite

Note: If you are unfamiliar with conditional logic in WPForms, we highly recommend that you check out our guide to learn more.

That’s it! You now know how to install and use the MailerLite addon for WPForms!

Next, would you like to know how to set up conditional logic to send email notifications for your forms? Learn more by checking out our complete tutorial.