Do you want to create optin campaigns using custom JavaScript variable rules?

If you’ve worked with JavaScript in the past (or you have an interest in learning), you’re sitting on an incredibly effective tool for increasing your conversions. That’s because you can use custom JavaScript variables to create high-converting optin campaigns that are seen when, where, and exactly to whom you want.

With custom JavaScript, you can make sure you’re showing the right offers to the right people at just the right time in their customer journey.

This not only leads to providing a better user experience (UX) across your site, but it also leads to more conversions and sales for you.

Get TOTAL Control With JavaScript Variable Rules

Using our JavaScript variable rules to trigger a campaign is an advanced feature that you can use if you (or your developer) have a working knowledge of JavaScript.

javascript variable targeting

Whereas the HTML element lets you create A LOT of personalized triggers for your campaign, JavaScript variables literally make the options limitless.

In other words, if you or your developer understand and use JavaScript, you can literally make a trigger for anything on your website.

JavaScript Variable Rules for eCommerce

Adding JavaScript rules to your optin campaigns can do wonders for your online store. It can help business owners:

  • Make targeted product recommendations in the customer’s shopping cart
  • Reduce shopping cart abandonment with item-specific recommendations
  • Display campaigns based on user behavior
  • Personalize UX to display campaigns that your customers will find most interesting

If you know enough JavaScript, the sky really is the limit.

Now, in most cases, our native display rules will have you covered. But sometimes, you’ll want a custom trigger for more complex scenarios.

With OptinMonster’s JavaScript variable rules, online store owners have complete control how your optin campaigns function.

JavaScript Variable Rules for Online Publishers

The benefits of custom JavaScript variable rules aren’t exclusive to the world of eCommerce. You can also use JavaScript to customize your optin campaigns if you’re an online publisher or affiliate marketer.

As an example, let’s say you have infinite scroll JavaScript on your blog’s homepage. That means whenever the reader gets within 500px of the page’s footer, your JavaScript rule will fetch new article suggestions for your reader.

javascript variable rule

With OptinMonster, you can create a special rule to display your optin campaigns whenever a certain number of new post suggestions are loaded.

So when a user gets their first round of article suggestions, they’ll see a campaign related to the blog’s content. Then, when they get another round of article suggestions, they’ll see another targeted campaign (and so on).

That kind of campaign might look like this:

This leads to a more personalized UX which, in turn, gets you higher conversions.

Again, this is just one of the many use cases for this advanced feature, but there are many others. The point is that our JavaScript variable trigger gives you 100% control over your lead generation strategy.

And as a result, you can get higher conversions and drastically increase your profits.

Ready to get started targeting your audience and boosting conversions? Start your risk-free OptinMonster account today!