How to create unique coupons for Woocommerce
You will learn
Learn how to create unique, single-use coupons for your WooCommerce store and use them in flows to incentivize subscribers to make a purchase. To do this, you’ll first create your coupon in WooCommerce, then configure settings for the linked coupon in Klaviyo.
Unique coupon codes for WooCommerce can be used in flow emails only, not campaign emails. If you’d like to include a coupon in a campaign, consider uploading unique codes or using a static WooCommerce coupon.
Use cases for unique coupon codes in flows
- Abandoned cart
Send a discount code that’s only active for a limited amount of time (e.g., 2 to 4 days) to cart abandoners who haven’t purchased before to create a sense of urgency and encourage conversions from casual browsers. - Winback
Send a discount code to buyers who haven’t purchased recently to incentivize them to purchase again. Similar to the abandoned cart coupon logic, sending a coupon with a set expiration date can create a sense of urgency and prompt a purchase. - Welcome series
Send a discount code to new subscribers as soon as they join your email list. You can send another code with increased incentive if they still haven’t made a purchase after 2 weeks.
Before you begin
Make sure that you’ve integrated with WooCommerce and have permission to view and manage coupons in Klaviyo. Navigate to Content > Coupons. If the WooCommerce Coupons tab is missing, check your integration:
- Select Integrations in Klaviyo’s left-hand navigation.
- Search for WooCommerce, then select it.
- Review your WooCommerce connection and complete any unfinished setup. If you edit the integration settings, click Save settings.
You'll need to enable coupons in WooCommerce, if you haven't already:
- Log in to your WooCommerce account.
- Head to WooCommerce > Settings > General and check the box to enable the use of coupons.

- Save your changes.
Create your coupon in WooCommerce
- In your WooCommerce account, navigate to Marketing > Coupons.
- Click Add new coupon. If you have not created a coupon yet, use the prompt to create your first coupon.

- Enter a Coupon code and an optional description for your own use. To link the code in Klaviyo, use no more than 32 characters and only letters, numbers, and underscores.
- Enter your coupon data. This includes:
- Discount type
- Coupon amount
- Allow free shipping
- Coupon expiry date
- If you have any Usage restrictions or Usage limits, enter them in the respective tabs under Coupon Data.
To make each generated code single-use, set Usage limit per coupon to 1. We also recommend setting Usage limit per user to 1. Klaviyo copies these limits from your WooCommerce coupon to the generated codes.
- Once you’re finished editing, click Publish so your coupon is ready to use.
Configure your coupon in Klaviyo
Now that you’ve created your coupon in WooCommerce, configure it in Klaviyo so you can generate codes for your flows.
- Navigate to Content > Coupons in Klaviyo’s left-hand navigation.
- In the menu bar along the top, select the WooCommerce Coupons tab.

- Select Create WooCommerce Coupon.
- Select Add code, then enter the coupon code you created in WooCommerce. It should be the same code name you assigned to the linked coupon in WooCommerce.

- Click Save.
- Set the following properties for your coupon:
- Prefix
Klaviyo adds up to 10 random letters and numbers after an optional prefix (e.g., JB20). The prefix can contain up to 25 letters, numbers, or hyphens. The full code is limited to 32 characters.
- Prefix
Note that WooCommerce stores all coupon codes in lowercase. For example, if you input JB20 as the prefix, a full unique code would show as jb20h3shfr7kgs when it’s created.
- Quantity
Enter a Minimum inventory between 1 and 150,000. Klaviyo uses this value to generate an initial batch of codes and replenish codes as needed for flows. We recommend choosing the number you reasonably expect to use in a day (e.g., 10). - Expiry date
Choose when your coupon codes expire: After a certain number of days or On a specific date. For either option, set the expiry time and time zone. Klaviyo uses your account’s time zone initially, but you can change it. The expiry set in Klaviyo overrides the WooCommerce coupon’s expiry for the generated codes.

- Click Create coupon.
Keep the source coupon code in WooCommerce unchanged after you link it to Klaviyo. Klaviyo looks up that code when generating new codes. If it is renamed or deleted, restore the original code in WooCommerce or create a new coupon in Klaviyo linked to an existing WooCommerce code.
Once you have created your coupon in WooCommerce and configured it in Klaviyo, Klaviyo will begin generating codes automatically for your flow emails.
Use your unique coupon in a flow
Once you’ve created and configured your coupon, insert it into a flow email.
- Navigate to the Flows tab in Klaviyo’s left-hand navigation.
- Open an existing flow or create a new one.
- Select a flow email inside your flow.
- Open the message editor for the selected flow email.
- Click inside the text field where you want the coupon, then click the personalization icon. Depending on your editor, you may see a person icon or a button labeled Personalization.

- From the All types menu, select Coupons.

- Select the coupon you’d like to add. Save your changes and return to the flow builder.
- Optional: Select the 3 dots on your flow email, then click Preview. The in-app preview shows your coupon’s name followed by “-PREVIEW” instead of a redeemable code. When the email is sent, Klaviyo assigns a code from the available inventory to the recipient.

When emails are sent, a unique discount code, consisting of your optional prefix followed by up to 10 random letters and numbers, replaces the coupon tag for each recipient. If you include the same coupon tag in multiple flow emails, the recipient receives the same code while it remains unexpired.

Klaviyo generates an initial batch of unique codes when you create the coupon, based on Minimum inventory in the Quantity section. For example, a minimum inventory of 100 requests an initial batch of 100 codes.
For coupons set to expire After a certain number of days, Klaviyo checks inventory on a schedule and replenishes available codes up to your minimum inventory. For either expiry option, if a flow email needs a code and none is available, Klaviyo requests more codes. The email can be delayed while generation completes.
Because Klaviyo can generate more codes as flows need them, you do not need to manually add batches using Add codes. If code generation fails, check the coupon and integration settings using the troubleshooting steps below.
Test your coupon
Before sending the coupon to your audience, test it using an email address you control. The steps below set the selected email to Manual, so it waits for your approval before sending. Other live messages in the flow can still send to your test profile.
- In the flow builder, open the status dropdown on the email you want to test.
- Select Manual.
- Trigger your flow using your test email address (e.g., fill out a sign-up form to join the list that triggers the flow). Make sure your test profile meets the flow’s trigger and profile filters.
- Wait for your test profile to reach the email after any time delays. With the email in Manual, the profile appears in Needs Review.
- Select the email, click View details, and open Recipient activity > Needs Review.

- Find your test profile and select Send Now next to it.

If no coupon code is available when you send the test email, delivery can be delayed while Klaviyo generates more codes and retries the send. If the email does not arrive, check Recipient activity and the troubleshooting steps below.
- Check your inbox for the email with the unique code. Apply the code to a cart in your WooCommerce store and confirm that the discount and usage restrictions match your offer.
When you’re ready to send automatically, set the email’s status to Live. Messages already in Needs Review still need to be sent or canceled manually.
Troubleshooting common coupon issues
If you are seeing issues with creating unique coupons for WooCommerce in Klaviyo, go through the following recommended troubleshooting steps. If you are still seeing issues after going through the recommended steps, reach out to Klaviyo’s support team for further assistance.
Check your WooCommerce integration settings
If your integration with WooCommerce is not syncing, or your WooCommerce store is unreachable, Klaviyo will not be able to generate new coupon codes.
To view your WooCommerce integration settings:
- Select Integrations in Klaviyo’s left-hand navigation.
- Search for WooCommerce, then select it.
- Review your connection settings. If you make changes, click Save settings.
For more assistance on configuring your Klaviyo integration with WooCommerce, see Getting Started with WooCommerce.
Decrease the quantity set for coupon codes
If you are experiencing an error creating coupon codes, try reducing Minimum inventory in the Quantity section of your coupon settings in Klaviyo.
Verify the coupon exists in WooCommerce
If you receive an error indicating that the coupon cannot be found in WooCommerce, Klaviyo is not able to match the specified coupon to one in your WooCommerce account.
If you are still creating the coupon in Klaviyo, correct the code so it matches an existing coupon in WooCommerce. If you already saved it, you cannot change the linked code in Klaviyo. Restore that code in WooCommerce, or create a new coupon in Klaviyo linked to an existing WooCommerce code and replace the old coupon tag in your flow emails.
Check for potential incompatibility with the Jetpack plugin for WooCommerce
If you notice that your coupon codes are running low or failing to replenish, this may be due to an incompatibility of Klaviyo’s coupon service with the Jetpack plugin for WooCommerce. If you have this plugin installed, please disable it.
Additional resources
- Getting started with coupon codes in Klaviyo
Learn how to create and upload unique and static coupon codes in Klaviyo to incentivize customers to engage with your brand. Offering an incentive can help you improve the customer experience, resulting in higher sales and increased lifetime value.
- How to set up static coupons for WooCommerce
Learn how to create and use static WooCommerce coupon codes to incentivize new sign-ups and encourage past customers to make another purchase.
- How to use unique coupon codes in SMS and MMS messages
Learn how to use unique coupons in your SMS/MMS messages so that you can send one-time-use coupons to your SMS subscribers and encourage them to make a purchase.