← All recipes
✓ Available · copy-paste buildStarter

Welcome Discount Guard

Catches the same person reusing your first-order discount under a new email (Gmail tricks, same phone or address), pauses shipping and emails you. Never cancels or refunds for you.

What it does: Shopify's "one use per customer" limit tracks the email address or phone number used at checkout, so a new email (and phone) gets your first-order discount again. This checks every order that used your first-order code against your earlier orders. 1. Spot the repeat. When an order uses your welcome code, it's compared with your recent orders by email, phone and address. 2. Pause and tell you. A match is tagged welcome-reuse (order and customer), its shipping is paused, and you get an email saying which earlier order it matched. 3. You decide. Let it go, cancel it, or mark a real new customer keep.

How it matches (you can read every rule): the same email ignoring case and +anything (and dots, for Gmail); the same phone, last 10 digits; or the same street line and ZIP, with Street/St, Apartment/Apt and # treated alike. Orders without your code are never touched. An order tagged keep is never flagged.

This is an automation, not AI. The checks are a short piece of plain JavaScript in Flow's Run code step. It never cancels, refunds or changes prices.

Why people want this: On r/shopify, an owner asked how to stop people who "keep creating new accounts with different email addresses just to reuse the 'new customer' discount multiple times" (reddit.com/r/shopify/comments/1u9i640). A Shopify Community thread asks the same about customers with the "same name and address but different email" (community.shopify.com/t/137709). Commenters suggest "looking for patterns in shipping addresses rather than just email addresses". This does that for you on every order.

How you install it

Copy-paste build, about 15 min. There's no one-click import file for this recipe yet. You create the workflows in Shopify Flow and paste in our exact settings, rules code and email text, step by step. Built from Shopify's documented Flow steps, with the rules code unit-tested; it hasn't been run end-to-end in our own test store yet, so the 14-day 'it didn't run' refund applies.

What it does

Shopify's one-use-per-customer limit only tracks the email or phone used at checkout. On every new order that used your first-order code, plain JavaScript rules in Flow's Run code step compare it with your recent orders (up to 100): the same email ignoring case, +tags and Gmail dots, the same phone (last 10 digits), or the same street line and ZIP with Street/St and Apt/# treated alike. A match is tagged welcome-reuse (order and customer), its shipping is paused and you get an email naming the earlier order it matched. Orders without your code are never touched.

Who it's for

  • Stores with a first-order or welcome code that keeps getting claimed again under new emails
  • Owners who see the same address or phone behind several 'new' customers
  • Anyone who doesn't want a monthly discount-abuse app

What you get

  • Exact copy-paste settings for one Shopify Flow workflow
  • Rules code for Flow's Run code step, with the test cases we ran
  • Step-by-step build checklist written for beginners
  • Match email text with what-to-do steps (let it go, cancel, or keep)
  • Settings for several codes or unique codes (WELCOME-*)
  • Free discount settings that make the code harder to farm
  • Store profile worksheet to tailor it to your store
  • Test plan so you know it works
  • Safety rails: tags and shipping holds only, never cancels or changes prices; keep tag
  • 12 months of updates and a 14-day 'it didn't run' refund

Setup time and cost

Setup: ~15 min. Platform: Shopify Flow (free). Price: $39 one-time, or included in All-Access.

FAQ

Does it remove the discount at checkout?

No. Flow only sees orders after they're placed, so it pauses shipping and emails you. You can let it go, cancel it, or tag it keep. Removing a code at checkout needs a checkout app.

Will it cancel or refund orders?

No. It tags, holds shipping and emails you. It never changes prices.

Does it work with unique codes from my pop-up?

Yes. Put the shared start of the codes in the rules, for example WELCOME-*.

How far back does it look?

Your last 100 orders from the past 180 days by default. Busy stores can switch to comparing with the last 100 orders that used the code.

Is there a one-click import file?

Not yet. You build it by copying the exact settings and code from the guide, about 15 minutes. The matching rules are unit-tested, but it hasn't been run end-to-end in our own test store yet, so the 14-day 'it didn't run' refund applies.

Is this an AI agent?

No. Recipes are Shopify Flow automations, not AI. This one runs on its own inside Shopify Flow, following rules you can see. Our live AI product is AI Support Triage (https://www.agents4ecom.ai/ai/support-triage), which sorts support email and drafts replies for you to review. It's available to US stores only: $29/mo for 300 messages, or $49/mo for 1,500.

Do I need to be technical?

No. Copy and paste each setting from the step-by-step guide.

What if it doesn't work in my store?

You're covered by a 14-day 'it didn't run' refund.

Related guides

Setup checklist (3 steps)

  1. Open the Flow app and create the workflow: Order created, then Get order data with the query from the build guide.
  2. Paste the rules into Run code and change WELCOME10 to your first-order code.
  3. Unlocks after purchase · copy-paste settings included

The full checklist, copy-paste settings and troubleshooting guide unlock after purchase.