How to Connect Mailchimp to WordPress With a Signup Form That Matches Your Site
You’ve got a Mailchimp audience and a WordPress site, and all you want is to connect Mailchimp to WordPress so one feeds the other. So why does the signup box you pasted in from Mailchimp look like it wandered over from somebody else’s website, with the wrong font, the wrong button, and a little gray box sitting next to forms that look nothing like it? And why can’t the contact form you already have just ask “Want our newsletter?” and take care of the rest?
Search for help and you get a pile of answers that don’t agree: paste the embed code, install a Mailchimp plugin, use a form plugin, hire someone. Meanwhile the signups keep landing in your inbox, and every so often you’re copying email addresses into Mailchimp by hand, hoping you didn’t miss one.
Yes, it’s a lot of noise. But the fix is a lot smaller than it looks. Below, you’ll build a Mailchimp signup form in WordPress that looks like the rest of your site, drops every new subscriber into the right audience on its own, and can ride along on the forms you already have.
What you’ll need
- Ninja Forms (free)
- The Mailchimp add-on (standalone, or included with the Plus membership and higher)
- A Mailchimp account with at least one audience
What’s the best way to connect Mailchimp to WordPress?
The best way to connect Mailchimp to WordPress for most sites is a form plugin with a Mailchimp integration. You build the signup form in WordPress, so it looks like your site, and the plugin hands each new subscriber to your Mailchimp audience when the form is submitted. The same connection also works on forms you already run, like a contact or quote form.
You’ve got three common options, and here’s how they stack up:
- Mailchimp’s embed code. Free and fast, but it brings Mailchimp’s look with it, and it can’t add a “subscribe me” box to a form you already have.
- A Mailchimp-only plugin. It works, but it’s one more plugin with its own forms to manage next to the ones you already use.
- A form plugin with a Mailchimp add-on. One set of forms, your site’s styling, and any form can grow a newsletter signup.
We’ll take door number three. If you already use Ninja Forms for your contact form, you’re most of the way there.
Connect your Mailchimp account with one API key
Ninja Forms talks to Mailchimp through an API key, which is basically a password Mailchimp gives your site so the two can talk. You paste it in once, and every form on your site can use it.
- In your Mailchimp account, create an API key and copy it.
- In your WordPress admin, go to Ninja Forms > Settings.
- Scroll to the Mailchimp section and paste the key into API Key.
- Click Save Settings.
Where the Mailchimp section sits depends on which other add-ons you have, so look for its heading rather than counting sections. That’s the only trip to Settings you’ll need.
Build a signup form that looks like the rest of your site
Already have a contact form you want to add a newsletter signup to? Just open it and skip on down to the opt-in checkbox. Starting fresh is quick too.
- Go to Ninja Forms > Add New and choose Blank Form.
- In the Form Fields tab, click the blue (+) icon to open the Fields window.
- Under User Information Fields, add First Name, Last Name, and Email.
- Click the Email field to open its field settings window and turn on Required Field.
Mailchimp needs an email address for every subscriber, so making Email required means nobody can send you a signup Mailchimp will turn away.
Here’s the part the embed code can’t match. Your form picks up your theme’s fonts and colors on its own, so it looks like it belongs.
Want more polish? Our guide to form design covers the free Opinionated Styles setting and the Layout & Styles add-on for a fully branded look.
Once your API key is saved, Add New also offers a Mailchimp Signup Form template that builds the fields from your audience for you. It’s a nice head start, but it adds a field for every field in your audience, so expect to delete a few, and it doesn’t include the opt-in checkbox coming up next.
Let people choose to subscribe with the Mailchimp Opt-In field
The Mailchimp Opt-In field is a checkbox that decides whether a submission goes to Mailchimp. Ticked, the person is subscribed. Unticked, the form still submits and saves the entry like normal, and Mailchimp is skipped for that person.
On a form whose only job is newsletter signup, you can leave it off. On a contact form, a quote request, or anything else, add it, because people who asked you a question didn’t necessarily ask for your newsletter.
- In the Form Fields tab, click the blue (+) icon to open the Fields window.
- Under Common Fields, click Mailchimp Opt-In.
- Click the new field to open its field settings window, and write the Label in plain words.
- Leave Default Value set to Unchecked.
A good label says what people get and how often. Our demo form for a llama trekking outfit reads “Yes, send me Trail Notes: new trek dates and llama news, about twice a month.”
A pre-ticked box isn’t real consent, which is why Unchecked stays the default. Our GDPR checklist for WordPress forms goes deeper on that.
Send every signup to your Mailchimp audience
This is where your form and Mailchimp actually shake hands. You add the Mailchimp action, pick the audience, and tell it which form field goes where. It sounds technical, but it’s mostly picking from dropdowns.
One thing to know before you start mapping: any field your Mailchimp audience marks as required has to be matched to a form field here, or Mailchimp turns the signup away. If your audience requires something like a phone number, add that field to your form first.
- Click the Emails & Actions tab, then the blue (+) icon to open the Actions window.
- Under Installed Add-on Actions, click Mailchimp.
- In the List dropdown, choose your audience.
- Under List Field Mapping, click into Email (required) and pick your Email field.
- Do the same for your audience’s other fields, commonly First Name and Last Name.
- Click Publish.
Why does the dropdown say List when Mailchimp says audience? Mailchimp renamed lists to audiences a while back, and the label in the add-on kept the old name. Same thing.
Just made a new audience or field in Mailchimp? Click the circular arrows next to the List label to refresh.
That’s all there is to it. Your form now sends every opted-in signup to Mailchimp, and someone who signs up twice gets their existing contact updated rather than a duplicate.
Add double opt-in, tags, and groups when you want them
Everything above is enough to start collecting subscribers. These three extras live in the same Mailchimp action, and each one is optional.
Ask new subscribers to confirm by email
In the Mailchimp action, expand Advanced and turn on Require subscribers to confirm their subscription. Mailchimp then emails each new subscriber a confirmation link, and they stay pending until they click it. It’s off by default.
Tag signups so you know where they came from
At the bottom of List Field Mapping, type tag names into Tags, comma-separated, for example website-signup. Tags have to exist in Mailchimp already and match exactly, capital letters included.
Want the form to create new tags for you? Turn on Allow creation of NEW tags from submitted values under Advanced.
Put subscribers into Mailchimp groups
Tick groups under Interest Groups in the action, and everyone who submits the form lands in them. Want visitors to pick their own groups? The Mailchimp Signup Form template from above sets that up for you, which is much easier than wiring it by hand.
Running separate audiences, like one for customers and one for everyone else? Add one Mailchimp action per audience, and use each action’s Conditional Logic settings with the Conditional Logic add-on to pick one based on an answer.
Need to send hidden details like the page someone signed up from? Here’s how to send custom data to Mailchimp.
Test your Mailchimp signup form with your own email
Before you announce anything, embed the form on a page with the Ninja Forms block or its shortcode. Then fill it out yourself with an inbox you own, tick the box, and check your audience in Mailchimp. If you turned on double opt-in, confirm from your inbox first.
Don’t see yourself? No worries. Your visitor sees the same success message either way, so the problem only shows up on your side.
Keep the form’s Record Submission action on, because that’s how you’ll find it.
- Go to Ninja Forms > Submissions and select your form.
- Hover over your test entry and click Edit.
- Read Mailchimp’s response in the panel on that page.
It’s usually a required Mailchimp field that isn’t mapped, a tag that doesn’t match, or the wrong audience in the List dropdown. Fix it, submit again, and you’re set. The Mailchimp add-on documentation covers the rarer cases, like date and address fields.
Start growing your Mailchimp audience from your own forms
Remember that gray box that didn’t match your site, and the email addresses you kept copying over by hand? Both are gone. You now have a signup form that looks like your site, adds subscribers to Mailchimp on its own, and can sit on any form you run, with a checkbox so nobody gets a newsletter they didn’t ask for.
For most sites that’s the best way to connect Mailchimp to WordPress, because your list grows from forms you’re already using. Ready to start? Pick up the Mailchimp add-on, or get it along with a lot more add-ons in the Plus membership and higher.
Try Ninja Forms Today
Always free, with premium features available through our memberships.
I would like to use my Ninja form to tag users in Mail Chimp when they sign up. I want to tag them differently depending on which page they signed up on. Is this possible and, if so, how do I do it?
Liat,
Hey! You can:
– Add a Text or other field in your MailChimp list
– In the MailChimp action of the form, set one of the post/page specific merge tags as the value of that field. For example, {wp:post_url}
When the form is submitted, it will pass the post/page data captured by the merge tag into your MailChimp list.
Hope that’s what you’re looking for, and this is a great topic for a future blog post. Thanks for the great question!
Cheers,
Quay
Thank you so much, Quay, for the fast and helpful response!
That IS what I’m looking for, and I’m going to go try it right now. I do hope you do a blog post on this in the future, I would love to see other examples of using Ninja Forms to pass through segmentation data to MailChimp.
-Liat
Can one form take a paypal payment and send form information to mailchimp?
Sure! You’ll need the PayPal Express add-on to connect your forms to your PayPal account for payment. You can have both Mailchimp and Paypal set up on the same form.
Cheers,
Quay