Reminder: By Aug 31, 2025, all new apps and updates to existing apps must use Billing Library version 7 or newer. If you need more time to update your app, you can request an extension until Nov 1, 2025. Learn about Play Billing Library version deprecation.
[null,null,["最后更新时间 (UTC):2025-07-27。"],[],[],null,["# Promo codes\n\nPromotions, or *promo codes*, enable you to give one-time products or trials\nto subscriptions free-of-charge to a limited number of users. The user enters\na promo code, either in your app or in the Google Play Store app, and receives\nthe item or subscription trial at no cost.\n\nWithin the Play Console, you can create the following types of promo codes:\n\n- **One-time use codes**: These are automatically-generated unique codes that users can redeem only once. Users redeem these codes either directly from the Play Store or from within your app.\n- **Custom codes**: You can specify custom codes that can be redeemed multiple times up to your predefined limit. Custom codes are available only for subscriptions and can be redeemed only by users who have not previously subscribed.\n\nYou can use promo codes in many ways to creatively engage with users,\nincluding the following:\n\n- You might distribute cards with promo codes at an event, and users would enter their promo codes to unlock a special in-game item.\n- You might give codes to employees so they can share them with their friends and family.\n- You might send a promo code to people who buy your app during a certain period of time.\n\nFor subscriptions, note the following:\n\n- Promo codes offer free trials to subscriptions and not free subscriptions.\n- Promotions do not extend other free trials. If a subscription begins with a free trial without requiring a promo code, a promotion would override the original free trial length.\n- Users who would otherwise not be eligible for free trials---for example, users who had purchased a subscription in the past but are no longer subscribed---are still eligible for a free trial through a promotion.\n- You can create only one promo code per subscription product. That is, you can create a promo code only for a single base plan or offer.\n\nUsers can redeem promo codes in the Google Play Store up until a promotion\nend date that you specify in the Play Console. Promotions can last up to\none year.\n\nBefore implementing a promotion, be sure to consider the following:\n\n- For one-time products, you can create up to **500 promo codes per quarter** across all managed products in an app. You can use different combinations of promo codes that include one or more one-time products. Examples include the following:\n - 500 promo codes for a single one-time product.\n - 100 promo codes, each for five different one-time products.\n- For subscription promotions, you can create up to **10,000 *one-time use codes* per quarter per subscription product**. This limit does not count toward the limit of promo codes for one-time products.\n- When creating a subscription promotion with custom codes, you can choose a redemption limit between 2,000 and 99,999.\n\n| **Note:** Once you create a promotion, you can't change the number of promo codes in that promotion, and you can't switch those promo codes to a different type.\n| **Note:** If you don't use all of your promo codes in a quarter, you lose access to them. Unused codes don't carry over to the next quarter.\n\nCreating and managing promotions\n--------------------------------\n\nTo learn how to set up and manage promotions, see\n[Create Promotions](https://support.google.com/googleplay/android-developer/answer/6321495).\n\nUser redemption flow\n--------------------\n\nOnce a user has a promo code, they can redeem it in one of the following ways:\n\n- **In your app:** The user can initiate the purchase by clicking the down arrow next to the form of payment in the Google Play purchase screen and then clicking the **Redeem** link to type in the code.\n- **In the Play store:** The user can manually enter the code in the Google Play Store by clicking the Play Store left navigation menu and tapping **Redeem Code** .\n - The user can also skip manual code entry by instead following a [deep link](#deep-link) to the Google Play Store.\n\nAs an example, figure 1 shows a purchase screen for a subscription. To enter\na promo code, tap the arrow next to the current payment method to show the\n**Payment methods** screen, as shown in figure 2. Next, tap **Redeem code**\nto go to the **Redeem a gift card or promo code** screen, as shown in figure 3.\nYou can then enter your promo code on this screen and tap *Redeem* to finish.\n**Figure 1.** A subscription purchase dialog. **Figure 2.** Screen that lists payment methods for an in-app purchase. **Figure 3.** Promo code screen.\n\nFor subscription promo codes, note the following:\n\n- Custom codes can be redeemed only from within your app, while one-time codes can be redeemed through both your app and the Play store.\n- After the user redeems the code, they still need to purchase the subscription with the code applied. A valid form of payment is required for the subscription, and the subscription will auto-renew at the end of the promo code free trial period.\n- If using Billing Library version 2.0 or higher, a user who redeems a one-time code from the Play store is immediately asked to purchase the subscription through the Play store. This is an out-of-app purchase, so be sure that your app can [handle these purchases gracefully](/google/play/billing/integrate#ooap).\n - If your app does not yet support Billing Library 2.0, the user must download your app, navigate to the correct subscription, and then purchase the subscription from within your app to use the promotion code.\n\nImplementing promo codes\n------------------------\n\nTo ensure your app is ready to handle promo codes, your app needs to\nproperly handle redemptions that occur outside of your app. To learn more,\nsee [Processing purchases](/google/play/billing/integrate#process),\n[Fetching purchases](/google/play/billing/integrate#fetch), and\n[Handling purchases made outside of your app](/google/play/billing/integrate#ooap)\nin [Integrate the Google Play Billing Library into your app](/google/play/billing/integrate).\n\nDeep link\n---------\n\nYou can also share a promo code by generating a URL that sends the user to\nthe Google Play Store and auto-populates the **Enter code** field. Use the\nfollowing format for a promo code URL: \n\n https://play.google.com/redeem?code=promo_code\n\nFigure 4 shows the Google Play app's **Redeem Code** dialog:\n**Figure 4.** Google Play app's **Redeem Code** dialog.\n\nAfter the user presses **Redeem**, if the latest version of your app is\ninstalled, the Google Play Store prompts the user to open the app. Otherwise,\nthe Google Play Store prompts the user to update or download your app.\n\nTesting promo codes\n-------------------\n\nTo test your promo code implementation, see\n[Test promo codes](/google/play/billing/test#promo)."]]