If you’ve tried embedding Mailchimp’s newsletter opt-in popups on your site, you may have noticed that these are only shown once to a visitor.
Turns out, Mailchimp has intentionally designed it to show once.
But there is a way to make Mailchimp pop-ups show more than once, by editing the code.
In this post, I’ll show you how to make your Mailchimp pop-ups show every time someone visits your site.
Plus, I’ll show you how to make the popup only appear if a user clicks somewhere.
Why Does Mailchimp Popup Only Shows Once?
The Mailchimp popup only shows once because that’s how Mailchimp has configured it to show. And they do not offer any tools to edit this.
⚡Also Read: Mailchimp pop-up not showing
However, that doesn’t mean we can’t do anything about it.
We can edit the popup script to appear everytime.
Mailchimp makes the popup show once using 2 cookies called MCPopupClosed and MCPopupSubscribed. Once a user visits our site, these are stored on their browser.
This means the popup will only show up for the user if they cleared their cache.
So, since this is controlled by cookies, all we have to do is unset them and the script will run every time someone visits our site.
Making The Pop-up Show More Than Once
Let’s edit the code. This is how your original code would usually look like:
Now we just need to add code to expire cookies at the bottom before the </script>
The two lines of code to unset cookies are:
document.cookie = “MCPopupClosed=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;”;
document.cookie = “MCPopupSubscribed=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;”;
That’s it! The subscribe popup will show every time someone visits your site!
⚡Also Read: Mailchimp This Page Appears To Be Missing Error
This is how the final code will look like:
If you don’t know much about code and are wondering how all the spaces and line breaks come, I just added them to look nice. This is completely fine too:
If you have a more complex code, check this out.
Mailchimp Popup On Click
You might also need to make the pop-up appear only when someone clicks something on the site, or otherwise you would get a ton of spam or bot sign-ups.
Let me show you how to make the mailchimp popup on click and remove cookies so that it shows all the time:
Making Mailchimp Popup On Click
Your original code will be the same:
We need to put our main code inside a new function and then call it only when a user clicks something. Here’s how to do it:
- Add a new function on the top after <script> as:
Function showPopup() {
- And then add the original code (without the </script> part).
- Add the cookie unsetting code
- Close the function
- Add the line to call the code when someone clicks:
document.getElementById(“show-popup”).onclick = function() { showPopup(); }
- Add the </script> closing tag.
Here’s how the fully modified code would look like then:
⚡Also Read: Sendinblue Emails Going To Spam
That’s it. Your subscribe opt-in pop up will show every time a user visits your websites and clicks on something.
Bottom Line
Mailchimp sets two cookies on users’ browsers after showing a pop up once and it will not show the pop to users who already have the cookies.
And they offer no tools to configure change popup settings.
But we can edit the script code and make popups show more than once. All you have to do is set the cookies as expired on their script and the pop up will be displayed for every visit.