How to run an affiliate program for your Android app on Google Play
To run an affiliate program for an Android app sold through Google Play, you attribute sales with codes, not links: each affiliate gets a personal code, the customer enters it in your app’s paywall, your app applies a discounted subscription offer, and Google Play’s real-time notifications let you tie that subscription — and every renewal, refund, and cancellation after it — back to the affiliate. Commissions are then calculated from that ledger.
This guide covers why the usual link-based approach under-reports on Android, and how to set up the code-based version step by step.
Why affiliate links break on Google Play
Classic affiliate tools track a click, drop a cookie, and wait for a conversion on a web page. A Google Play subscription doesn’t convert on a web page. The customer lands on the Play listing, installs the app, opens it — possibly days later — and subscribes through Google Play Billing, inside a purchase sheet no cookie can reach.
Android does have an install-referrer mechanism that can carry a parameter from a link click through to the install. It helps measure installs, but it’s a fragile basis for an affiliate program: it says nothing about whether the install ever became a paying subscriber, it doesn’t follow the subscription through renewals and refunds, and it breaks whenever the journey isn’t a straight line from one tapped link to one install on one device. Real journeys rarely are — someone hears a code in a podcast, searches the Play Store on their tablet that evening, subscribes a week later.
A code survives all of that, because the customer carries it themselves and uses it at the exact moment of purchase. The general principle is the same one we described for why affiliate tools miss mobile subscribers; here’s how it maps onto Google Play specifically.
The building blocks of an Android app affiliate program
Google Play gives you two code-shaped tools. Knowing which is which saves a lot of confusion:
Play promo codes (Play Console → Promotions) grant a free trial of 3–90 days, work only for customers who have never subscribed, and apply only to backwards-compatible base plans. They’re useful for giveaways and press. They are not a percentage discount, which makes them a poor fit for a standing “20% off with my code” affiliate pitch.
Subscription offers on a base plan are the tool that fits. Since Play Billing 5, each base plan can carry offers with discounted pricing phases — for example, a reduced price for the first year. An offer with developer-determined eligibility is shown only when your app decides to apply it. That’s the hook: your paywall asks for a code, validates it against your list of affiliate codes, and if it matches, launches the purchase with the discounted offer attached.
So on Android, the “code” is defined by you and applied by your app; Google Play executes the discounted purchase. Different plumbing than Apple’s offer codes, same outcome: attribution at the point of sale.
Step 1: Create the discounted offer in Play Console
In Play Console, open your subscription product and add an offer to the base plan you sell — typically the annual plan:
- Choose the base plan, give the offer a clear offer ID (e.g.
affiliate-20-first-year). - Set eligibility to developer determined, so it only appears when a valid code is entered.
- Add the pricing phase: the discounted price for the first billing period. The subscription renews at the base plan’s full price afterward.
One offer covers your whole program — you don’t need an offer per affiliate. The per-affiliate part is the code your app checks before applying it.
Step 2: Add code entry to your paywall
Add a “Have a code?” field to your paywall. When the customer enters a valid affiliate code, your app selects the discounted offer for the purchase flow and records which code was used, associated with the purchase. This is a small, one-time integration — on the order of 15 minutes with Play Billing 5+ already in place — and it’s the piece that makes the influencer’s pitch (“use code ANA20 in the app”) actually work.
Two details matter here. First, validate codes server-side or against a fetched list, so adding an affiliate never requires an app update. Second, store the code-to-purchase association somewhere durable, because the purchase is only the first event of many.
Step 3: Attribute the lifecycle with Real-time Developer Notifications
A subscription’s value unfolds over months: renewals, grace periods, refunds, cancellations. Google Play reports all of it through Real-time Developer Notifications (RTDN), delivered over Cloud Pub/Sub. Your backend subscribes, matches each event to the purchase — and therefore to the affiliate code — and appends it to a per-affiliate ledger.
This is the part a spreadsheet can’t do. A renewal that arrives in month eleven still owes a commission if your terms are recurring; a refund in week two should claw one back. If you’d rather not build and babysit that pipeline, this ledger is precisely what Affiliate Raccoon runs for you: store notifications flow in, every event lands against the right affiliate, and both you and the affiliate see the numbers update in real time.
Step 4: Set commission terms on net revenue
Define the rate (one-time or recurring), the payout threshold, and — important on Google Play just as on the App Store — the basis: net revenue, meaning what you receive after Google’s platform fee, not the sticker price. Put it in writing before the first invite. For benchmarks and a worked example, see how much commission should you pay app affiliates.
Step 5: Invite affiliates and close months cleanly
Each affiliate gets their personal code and a clear statement of terms. At month end, the numbers freeze: redemptions, renewals, minus refunds, commission per affiliate. The affiliate invoices you; you approve and pay. Commissions are tracked and calculated automatically — paying remains your deliberate final step.
Give affiliates visibility while the month runs. An affiliate who can watch subscribers and accrued commission accumulate under their code keeps promoting; one who’s in the dark stops.
FAQ
Can’t I just use Google Play promo codes for affiliates? For a trial-based giveaway, yes, within limits — Play allows up to 10,000 one-time codes per quarter per subscription product, and custom promo codes carry a minimum redemption limit of 2,000. But promo codes only grant free trials to never-subscribed users on backwards-compatible base plans. For a percentage discount that mirrors what affiliates promote on iOS, subscription offers applied in-app are the right mechanism.
Does this work if my app is on both stores? Yes, and it should: one program, one code per affiliate, working on both platforms. The iOS side runs on Apple’s offer codes — here’s the iOS setup guide.
What if a customer subscribes without entering a code? Then the sale is unattributed, correctly. Code-based attribution counts what affiliates actually drive; it doesn’t guess.
Want the whole thing — offers, codes, RTDN attribution, affiliate portals — set up in a guided onboarding instead of built by hand? Start a 7-day free trial.
Affiliate Raccoon