Feature Spotlight: Generating Unique, One-Time Coupon Codes for Shopify Plus

shopify coupon codes

As most of you already know, Klaviyo integrates seamlessly with both Shopify and Shopify’s enterprise solution, Shopify Plus. One key feature of Klaviyo’s integration with Shopify Plus is the ability to dynamically generate unique, one-time coupon codes within a flow email. This saves you the trouble of manually switching out coupon codes every so often and the worry of having your coupon codes posted on sites like Retailmenot. If you use coupon codes for promotional purposes and use Klaviyo with Shopify, consider upgrading to Shopify Plus to utilize this feature.

How it Works

Setting up coupon codes for your Shopify Plus store is a quick, 3-step process:

1. First, you’ll need to create a private API key in Shopify and send the API key and password to our success team to have this feature enabled.

2. Once this feature is enabled, you will see a Coupons tab on your sidebar. Inside this tab, you can create your coupon codes by selecting “Add Coupon.” Each coupon can be customized. You will set:

  • A name for the coupon (i.e. “Welcome_Coupon”).
  • A prefix — though each code will be unique, you can set a prefix that will be the same for each customer (i.e. “WELCOME—-”).
  • Discount type — this refers to whether a coupon code offers a percent discount, fixed amount off, or free shipping.
  • What items the coupon code applies to (i.e. specific products or collections).
  • How many days the coupon code will remain valid for.

3. Next, you can use dynamic tagging to refer to the specific coupon code you would like to use in your email. So, if we use the coupon name Welcome_Coupon, your tag will be: {% coupon_code ‘Welcome_Coupon’ %}. Like other tags, the coupon code will generate automatically wherever you place the tag in your template.


For more detailed information on how to set up coupon codes for your Shopify Plus account, check out our docs.

Use Cases

These coupon codes can be used wherever you offer promotions in your flow emails. Please note that these cannot be used in campaigns, since Shopify has a limit on how quickly these codes can be generated. However, since flow emails are often only updated periodically and aren’t sent in the same high-volume batches that campaigns are, these automated coupon codes will allow you to avoid editing all your flows to switch out new codes once the old ones expire.

Coupon codes are most often used in welcome series, abandoned carts, and win-back emails, but you can use them in any type of flow you’d like. There aren’t any limits on the number of coupon codes you can create.


While you should refresh your flow emails every so often to keep them timely and relevant, Klaviyo’s automatically generated, unique, one-time coupon codes will save you time and energy when it comes to updating coupon codes. Furthermore, it will eliminate the possibility of coupon code sharing, since each individual email recipient will get a unique code that they can use only once.


The 10 Point Ecommerce Email Marketing Checklist



Our 5 Favorite April Fools Day Emails



The Experience beyond the Product: An Intro to Customer Lifecycle Mana…


.yuzo_related_post img{width:260px !important; height:250px !important;}
.yuzo_related_post .relatedthumb{line-height:16px;background: !important;color:!important;}
.yuzo_related_post .relatedthumb:hover{background:#ffffff !important; -webkit-transition: background 0.2s linear; -moz-transition: background 0.2s linear; -o-transition: background 0.2s linear; transition: background 0.2s linear;;color:!important;}
.yuzo_related_post .relatedthumb a{color:#323b43!important;}
.yuzo_related_post .relatedthumb a:hover{ color:}!important;}
.yuzo_related_post .relatedthumb:hover a{ color:!important;}
.yuzo_related_post .yuzo_text {color:!important;}
.yuzo_related_post .relatedthumb:hover .yuzo_text {color:!important;}
.yuzo_related_post .relatedthumb{ margin: 0px 0px 0px 0px; padding: 5px 5px 5px 5px; }

jQuery(document).ready(function( $ ){
//jQuery(‘.yuzo_related_post’).equalizer({ overflow : ‘relatedthumb’ });
jQuery(‘.yuzo_related_post .yuzo_wraps’).equalizer({ columns : ‘> div’ });

Back to Blog Home
Get email marketing insights delivered straight to your inbox.