ReferralsTechnical

How to Build an Optimized Referral Program for Your Mobile App

By February 8, 2017 No Comments

Many teams think about growing their app’s user base via some sort of referral program. A referral program helps to create an awareness about one’s app by helping it grow in a viral, yet organic fashion. One of the most popular types of programs incentivizes its users to share app content with contacts and then credits them when contacts sign-up or perform certain actions in the app – like completing a purchase. If this is how you’re thinking about growing your app’s user base, then you’re on the right track, because building an incentivized referral program can do wonders to the growth of your user base.

Referral Program Features

When building  a referral program, it is important to understand the kinds of features that your app will need:

  1. Generate referral links.
  2. Share referral links.
  3. Track who your referred and referring users are.
  4. Provide analytics around who the most influential referrers are.
  5. Distribute credits based on actions performed by referring users/referred users through the use of referral rules.
  6. Allow users to redeem credit.
  7. Audit a user’s credit history.
  8. Optionality to help you build a personalized onboarding flow.

Most teams start off by implementing a subset of the features noted above – referral links, for example – and later realize that they need to scale to incorporate a more robust feature set, such as keeping track of a user’s credits.

What’s a Referring User?


If this is the first time you’ve heard about referral programs, there might be some ambiguity in the terms listed above. To help clear that ambiguity, I’ve provided definitions to terms that one should get acquainted with:

  1. Referring user – A user whose content brings a new or existing user into the app. You’ll want to make sure that these users get taken care of by giving them the highest tier of rewards in your app. This could be money, coupons or a status upgrade, etc.e.
  2. Referred user – A user who installs/opens the app via the influence of a referring user’s content.
  3. Referral rule – A rule that dictates by how much a user type should get credited when they trigger an event.
  4. Event – An action that any user takes inside the app – such as signing up for an account.
  5. Referred event – An action that a referred user takes inside the app.
  6. Credits – An in-app unit or currency specific to your app.
  7. Deep link – A route to a particular piece of content in your app.
  8. Referral link – A deep link created by a referring user.
  9. Onboarding flow – A set of screens that new users are greeted with the first time they install the app.

Now that you know what to look for in a referral program and are familiar with the vocabulary related to it, it’s time to cover the steps for launch. (little secret – Branch mobile referral features gives away items 1 – 8)

Here’s a quote from one of our partners who uses our referral links to drive adoption:


How to Launch a Credit Referral Program in 6 steps:

By the end of this guide, your users will be able to:

  1. Invite contacts into your app
  2. Get rewarded for referrals
  3. Review their credits
  4. Redeem credits

Branch allows an app to launch a credit referral program in six easy steps:

  1. Sign up and Integrate the Branch SDK.
  2. Create referral rules that target both referred user and referring users.
  3. Log users into Branch as soon as they login or create an account.
  4. Fire a Branch custom event every time users perform actions tied to your reward rules.
  5. Allow users to share links.
  6. Allow users to redeem credits.


Step 1: Sign up and integrate the Branch SDK

Follow our comprehensive onboarding flow (post sign up) to configure Dashboard and integrate the Branch SDK into your app.

And according to our Engineers, you can integrate Branch faster than your friend can finish their burrito.

Step 2: Create referral rules that target both referred and referring users

This is the foundational piece of our referral program’s setup. Branch needs to understand how many credits to allocate to both the referring user and the referred user when they perform an action in your app.

Follow the guide here to understand how to setup the various components of a reward rule in Dashboard.

For this demonstration, you’ll want to trigger both reward rules (from the guide) on the signup_completed event.

 


Step 3: Log users into Branch as soon as they login or create an account in your app

Assuming that you’ve gone through our comprehensive onboarding flow which includes integrating the SDK into your app, you’ll want to add some code to identify your users via a call to setIdentity() anytime users create an account or log into your app. Most developers pass the same username that users create into the setIdentity() function. This makes it easy to map users in your app to users in Branch.

After setIdentity() has been correctly implemented, if users create a link or cause an event to fire (discussed in step 4), they will be correctly attributed to it.

Step 4: Fire a Branch custom event every time a user performs an action

To get the reward rules created in step 2 to trigger, you’ll have to fire a signup_completed event from your app after users have created an account and you’ve identified them in Branch (step 3). This can be done by calling userCompletedAction(“signup_completed”).

Step 5: Allow users to share links 

Hands down, the easiest way to enable sharing in your app is to make a call to showShareSheet() on your Branch Universal Object (a single, self-contained object associated to each thing that you want to share). Calling this method will automatically generate a Branch link with the appropriate analytics channel when the user selects a sharing destination.


Step 6: Allow users to redeem credits

With the above steps configured correctly, referred users and referring users will get 10 and 5 credits respectively when a new user enters into the app via a Branch link and triggers the signup_completed event.

In order to redeem credits, your users will first need to know how many credits they have. For this, you would have to reserve a location in your app where users can see their balance and redeem credits.


Once you’ve figured out where you want to display a user’s credit balance, use loadRewards() to display how many credits a user has. When a user decides to spend credits in your app (for something awesome), simply call redeemRewards() for the amount that you wish to deduct from their balance.

A few additional points about our Dashboard:


Track Referred Installs on iOS and Android:

If you’re interested in seeing how many referred installs occur across iOS and Android, navigate to Dashboard > Summary > Click Flow.

         
Build a Personalized Onboarding Flow using getFirstReferringParams:

If you’re interested in building a personalized onboarding flow, then you can harness the data returned from getFirstReferringParams() It’ll contain information about the user that created the link that brought the current user into the app. This includes all of the link data associated it.

Here’s an example that showcases the referring user’s first name and last name to increase the likelihood of a sign up:


Who are my top influencers?


If you’re interested in who your top influencers are and who they’ve brought into the app, please navigate to Dashboard > Referrals > Influencers.


If you click on the number from the number of referred users column, you’ll get to see how many users a particular user has referred:


Give yourself a pat on the back for sticking with me through all of the guide and building a referral program with Branch. It’s not an easy task and you’ve had to learn a lot but it is going to be worth it in the long run. I sincerely hope that your app acquires a ton of users through it and that it makes the App/Play Store Hall Of Fame

Feel free to reach out to support@branch.io for any questions or inquiries related to our referral program and we’d be more than happy to assist your team.