Skip to main content

Hi 

I have a question around segmentation with discount codes. 

I wanted to make a segment of customers

  • who placed their first order with XXXXX discount code in the last 90 days but hasn't placed an order since. 
  • I want to catch anyone who used the XXXXX code above on their first order, but hasn't placed an order since (whether or not that's with the XXXXX code).

The segment I’ve built is below. I THINK that as I have defined that the placed order equals 1 exactly using XXXXX code that means that there have been no orders since at all (whether that’s with the XXXXX code or not). Is that correct?

This leads to the second question. Usually I would verify the segment by checking the profiles and that usually answers any questions. However, the profile activity doesn’t really show whether the XXXXX code has been used as it’s a code created in Shopify code. I know that when they are created via the Coupons section in Klaviyo they will show up on the profile in the coupons section but this isn’t the case with the codes not created in Klaviyo so I’m just predicting whether they used the code based on the discount in the order details. Are these codes that are made in Shopify viewable anywhere against the customer’s profile?

 

Thanks in advance for your help!

 

Sean

 

Hi Sean,

Great questions about segmentation with discount codes! Let me address both of your concerns:

The problem with your current setup:

Your segment currently has these conditions:

  1. Person has Placed Order zero times before Mar 25, 2025 (to identify first-time buyers)
  2. Person has Placed Order equals 1 after Mar 25, 2025 where Discount Codes contains the text [xxxxx]
  3. Person can receive email marketing because person Subscribed

The issue is that this logic doesn't ensure the person has only placed one order total. It only ensures they placed zero orders before a specific date and one order after that date, using the code. Someone could have placed multiple orders after March 25th and still meet these criteria.

Here's my suggested approach:

To achieve what you want (people who used XXXXX code on their first order in the last 90 days but haven't ordered since), you need:

Condition 1 (AND):

  • Person has Placed Order at least once in the last 90 days
  • where Discount Codes contains the text XXXXX

Condition 2 (AND):

  • Person has Placed Order equals 1 over all time

This ensures you're capturing people who both used the XXXXX code recently AND have only ever placed one order total, which guarantees they haven't ordered since that first purchase.

Your current setup is trying to use date-based logic to determine first-time buyers, but the simpler "equals 1 over all time" condition is much more reliable for identifying one-time purchasers.

AD_4nXdtZy66ipKsBKmH_qPZdRxbk5DSlWkTLkIPtmx45dUMOCpP-WWw4xx9WmwqaPZONnO7_qWWxEFfZp5QegpycnBlFwdeBuDYKUjVUH_lWct49QoZTeu5_WPkV10t0AawO0YfV5fWlw?key=LU6wk4Gkam4YydYcn4v28A

Regarding the Shopify discount code visibility - you're correct that these don't show in Klaviyo profiles currently, though this may improve with future Customer Hub updates.

Hope this helps clarify the segmentation logic.


Hi Obeth

This makes total sense - a much easier approach.

And noted on the Shopify discount codes on the profile - glad I wasn’t missing anything.

Thanks again for the explanation

Sean