You can easily incorporate scripts into your OptinMonster campaign to run after the optin has been successfully converted using the Success Scripts feature. This allows you to use scripts like Facebook’s tracking pixel and more.
In this article, you’ll learn how to use the Success Scripts feature in OptinMonster.
Before you start, this feature requires a Growth subscription.
Before you start, follow our guide for adding the Facebook Pixel to your campaign.
Add Success Script
When you create a campaign in OptinMonster you may wish to trigger specific scripts to run after the optin form is submitted.
To add a success script, follow these steps:
- From the Design view of the campaign builder, directly select the Optin Fields Block in your campaign.
- Next, expand the Success Script panel in the left pane of the builder.
- Add your script(s) to the provided field.
- When you’re finished, Save the campaign.
If you’re serious about jumpstarting your website business growth, then get started with OptinMonster today!
Get Started With OptinMonster Today!BONUS: Done-For-You Campaign Setup ($297 value)
Our conversion experts will design 1 free campaign for you to get maximum results – absolutely FREE!
Click here to get started →
Troubleshooting
Do I need to add <script>
tags?
Yes, your Javascript will need to be wrapped in <script></script>
tags to work properly.
Why can’t I load Javascript files into the page using the Success Scripts field?
It’s not possible to load Javascript files into the page using the Success Scripts field. Instead, you should load any file dependencies directly into the page on your website where you will be showing the campaign.