Referral program

A customer acquisition cost you pay only on success · Subscribers share a code, friends get a discount, advocates get rewarded

1. What the referral program does

Every active subscriber gets a unique referral code, shown in their customer portal with a shareable link. When a friend uses it to start their first subscription, the friend gets a discount on that order and the advocate is emailed a single-use reward code. You set both sides of the deal — and you only pay when a referral actually converts, which makes it one of the cheapest subscriber-acquisition channels a store can run.

Everything runs on real Shopify discount codes and the orders webhook — no cart scripts, no manual tracking, no spreadsheets.

Plan availability: the referral program is included on the Growth plan and above (Growth is $79/mo with a 30-day free trial). See sublyra.com/pricing.
Where it lives: Sublyra admin → Retention → Loyalty & referrals, in the Referral program section below the reward ladder.

2. How a referral works end to end

1 Code issued. While the program is on, each subscriber gets a unique referral code the first time Sublyra sees them. It appears in their customer portal with a shareable link.

2 Friend clicks the link. The link is Shopify's native discount link (your-shop.com/discount/CODE), so the friend's discount applies itself at checkout — no typing, no cart attributes, no storefront JavaScript.

3 Friend orders. The friend checks out with their first subscription. The orders webhook reads the discount codes on the order.

4 Conversion recorded. If the code belongs to a different customer, the order is paid, and it's the friend's first subscription order, a referral reward is queued for the advocate. Fraud guards in section 5 apply here.

5 Advocate rewarded. The job runner creates a single-use discount code worth your configured reward amount in Shopify, then emails it to the advocate: "Your referral reward is here — $15 off at Your Shop", with the code displayed and a Use my reward button that applies it automatically.

3. Set it up

Go to Retention → Loyalty & referrals → Referral program. Three settings:

SettingWhat it doesRange / default
Give subscribers a referral codeThe master switch. On means every subscriber gets a unique code and shareable link in their portal.Off by default
Advocate reward ($)The fixed amount the advocate's single-use reward code is worth, in dollars.$1–$500, default $15
Friend discount (%)The percentage off the friend's order when they use a referral code.5–60%, default 20%

1 Tick Give subscribers a referral code.

2 Set the advocate reward and friend discount. Total both sides and compare to your paid CAC — if a subscriber from ads costs you $40, a $15 reward plus 20% off a first order is usually money well spent.

3 Click Save referral settings. Codes start being issued to subscribers from that moment.

Grant the discounts permission first. Creating referral and reward codes needs the write_discounts permission. New installs grant everything on the single consent screen at install; if your store installed earlier, an amber "Additional permission needed" banner appears on the page with a Grant access button — click it before enabling the program, so codes can actually be created.

4. The two kinds of codes

Referral codes (advocate → friend)

Reward codes (you → advocate)

5. Fraud guards

Referral programs attract gaming, so the conversion rules are strict and applied identically on every order path:

GuardWhat it blocks
No self-referralsThe code's owner can't convert their own code — checked by customer record and by matching email address, so a second account with the same email doesn't slip through.
First subscription order onlyAny prior recorded order — checkout or recurring, any status — disqualifies the conversion. A returning customer is not a referral.
Paid orders onlyA pending or authorized charge hasn't converted. The reward queues only when the money lands.
Exactly once per orderThe conversion is keyed to the order, so a replayed webhook or a race between order paths can never queue the same reward twice.
Merchant codes ignoredA discount code that isn't a Sublyra referral code (your own marketing codes) is simply skipped.

6. Tracking and reward statuses

The Referral program section shows live stats:

Below them, the recent rewards list shows each reward with the advocate, amount, code and status:

StatusMeaning
PendingThe conversion was recorded; the reward code and email are queued. This is normal for a short window after the friend's order.
IssuedThe single-use code was created in Shopify and emailed to the advocate. Done.
SkippedDeliberately not fulfilled — for example the program was switched off before fulfilment, or the advocate's data was redacted under a privacy request (a redacted customer gets no email and no code in their name).
Every reward fulfilment is also written to the audit log and, for merchants listening on outbound webhooks, emitted as a loyalty.reward_earned event — so your own systems can react to referrals in real time. See the developer docs.

7. FAQ

Who receives the reward email?

The advocate, at the email address on their customer record — it's delivering something they earned. The one hard exception is privacy: customers whose data has been redacted under a GDPR request get no email and no code in their name, and the reward is marked skipped.

What happens if I turn the program off?

Unticking "Give subscribers a referral code" stops new conversions from recording and marks any still-pending rewards as skipped. Codes already in subscribers' hands remain valid Shopify discounts until you delete them under Discounts in Shopify admin — treat codes you've shared as permanent.

Can the same friend use two different advocates' codes?

No — first subscription order only. Once a customer has any recorded order, no referral code of theirs converts, whichever advocate's code they try.

Where do subscribers find their code?

In their customer portal, alongside a shareable link they can paste anywhere — messages, social, email. The portal preview in the Sublyra admin ("View as") shows you exactly what they see.

Which plan do I need?

Growth ($79/mo) and above include the referral program together with loyalty rewards, store credit and streaks. Paid plans start with a 30-day free trial.

Related guides