Skip to content
Hand-E Solutions, to the home page

Tips for your store

Referral codes: how customers bring in new customers

A referral code turns word of mouth into a program: your customer passes a code to friends, they save on their first order, and the customer earns a reward. Shopify gives you the codes, but it doesn't reward the referrer on its own. And if your store sends the invitation email itself, the law may treat it as your marketing email.

By Max Handrik · Updated October 13, 2026 · 6 min read

Comparison: one shared code like WELCOME10 ends up on coupon sites and works again with every new email address, a unique code like HALLO-7K2P works exactly once

1 How a referral program works

A referral program has three parts. The referrer, an existing customer, gets a personal code or link. The referred friend redeems it on their first order and saves. And the referrer earns a reward once the friend has bought.

You can reward one side or both. Shopify's guide describes double-sided discounts that benefit both the referrer and the referred friend. Behind this is trust: in a 2015 Nielsen survey, 83% of online respondents in 60 countries said they completely or somewhat trust recommendations from friends and family.

2 What Shopify can do on its own

You create the code for referred friends like any other discount code, under Discounts > Create discount. The steps are in our guide to creating a discount code. For a referral program, these settings matter most:

  • “Limit to one per customer”: Shopify recognizes the customer by email address or phone number.
  • “Limit number of times this discount can be used in total”: caps how often the code works overall, in case it spreads.
  • Minimum requirements: a minimum purchase amount makes sure the first order still pays off for you.
  • “Promote” > “Get a shareable discount code”: a link that puts the code in the cart when opened, plus a QR code. It only works while the discount is active.

3 What Shopify can't do: reward the referrer

A discount code doesn't know who passed it on. Shopify's discount settings have nothing that recognizes a referrer and credits them a reward after their friend buys. Shopify's own guide to referral programs points to referral apps in the Shopify App Store for that.

A referral app handles the missing part: it matches the friend's order to the referrer and hands out the reward. Ask before you install one: When does a referral count, at purchase or after the return window? Does the app catch self-referrals? Is the reward a discount code, points or money?

4 Protect the program from abuse

A known gap is self-referral: a customer redeems their own code with a second email address. “Once per customer” only slows this down, because Shopify recognizes the customer by email address or phone number. So only pay the reward once the friend's order is paid and can no longer be returned, and compare name and shipping address with the referrer's.

A code can also end up on coupon sites. According to the trade magazine Modern Retail, codes spread quickly through browser extensions like Honey. Personal codes that work only once limit the damage. How to generate hundreds of them at once is covered in our guide to unique bulk discount codes.

Be careful with customer segments: if you limit the code to a segment, Shopify says it only applies to customers who already have a customer profile in your store. Someone ordering for the first time doesn't have one yet, and that's usually exactly the referred friend.

5 Rewards and invitation emails: the rules

In the US, the FTC says that if a seller offers money, coupons or discounts for forwarding a message, the seller may be responsible for following the CAN-SPAM Act. And when a customer shares your link and gets something for it, such as a discount on a future purchase, the FTC says a disclosure is appropriate.

In Germany, the Federal Court of Justice ruled in 2013 that a store's “recommend to a friend” form counts as the store's own marketing email. Without the recipient's prior consent, it's unlawful there. The safer setup is to let customers pass the code on themselves, in their own message. And the email that sends your customers their code is marketing too, so send it to subscribers who opted in. This isn't legal advice.

6 Measure what the program brings in

Shopify's “Sales by discount codes” report groups your sales by discount and discount code. It shows how often the referral codes are redeemed. Then work out what a referred customer costs you: the friend's discount plus the referrer's reward. Compare that with what a new customer costs you through ads.

Referred customers refer more themselves. A study in the Journal of Marketing Research found that they made 31% to 57% more referrals than non-referred customers with comparable purchase activity. So remind referred customers that they came through a referral, and give them a code of their own right away.

Common questions

What is a referral code?
A personal code that a customer passes on to friends. The friend saves on their purchase with it, and the referrer can earn a reward. In German it's called an Empfehlungscode.
Can Shopify reward the referrer automatically?
Not with its built-in discounts. A discount code doesn't know who passed it on. You need a referral app for that, or you hand out the reward yourself, for example as a second discount code.
Can I reward customers for referring friends?
Generally yes. In the US, the FTC expects customers who share your link for a reward to disclose it, and emails you incentivize can fall under CAN-SPAM. In Germany, recommendation emails sent by your store need the recipient's prior consent. This isn't legal advice.
What's the difference between a referral code and an affiliate code?
A customer passes a referral code on to friends. An affiliate or partner code belongs to an influencer or partner who gets paid for their reach, for example with commission, and has to disclose it. More in our guide to influencer and partner codes.