> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.kiwify.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# How to integrate with Mailchimp

# How to integrate with Mailchimp

You can use Kiwify's integration with Mailchimp to add tags to your contacts based on the product and purchase event (for example: purchase approved, purchase declined), enabling you to create email marketing automations. 

If you don't have an account yet, you can create one on the https://mailchimp.com/

### Retrieving your Mailchimp API Key

To integrate Kiwify with Mailchimp, you'll first need to get your Mailchimp API Key:

Log in to your Mailchimp account.


Click on the button in the lower left corner of the screen, and then on the **Account & billing** menu:

![](https://storage.crisp.chat/users/helpdesk/website/bceda219e6714000/screenshot46_o3v1ml.png)

Next click on **Extras > API Keys**

![](https://storage.crisp.chat/users/helpdesk/website/bceda219e6714000/screenshot-at-apr-13-14-43-34_lnd2o8.png)

If you don't have an API Key yet, you can click the **Create a Key** button.

Copy the API Key you just generated.


![](https://storage.crisp.chat/users/helpdesk/website/bceda219e6714000/screenshot-at-apr-13-14-44-27_n6vkoz.png)

Return to the Kiwify dashboard and click on **Apps** > Mailchimp > Add Account.

Enter the API Key you just copied.

![](https://storage.crisp.chat/users/helpdesk/website/f11c2d2e7f47d000/screenshot139_1fbrqps.png)

After saving, click on the account you just connected to create the integration rules.

### Creating Integration Rules

Kiwify's integration works using a rules system. Each rule is product-specific and gets triggered based on an event (approved purchase, declined purchase, refunded purchase, etc.). 

When the event configured in the rule occurs, an action is carried out, such as adding or removing tags or lists on the Mailchimp contact.

Note: If the contact is new, a new contact will be added to Mailchimp. But if the contact already exists, the rule will just add/remove a tag or list.

|| Remember: The tags and lists that appear for selection are imported directly from your Mailchimp account. You must create the tags and lists in Mailchimp before integrating.

After creating the rule, make sure to click on "Save Changes". You can repeat this process and create as many rules as you need.

|| Note: Each rule is necessarily linked to a product. It is not possible to create a single rule for "all products".