Skip to main content
Question

How to check user eligibility for free trial using KMP SDK

  • September 28, 2025
  • 3 replies
  • 57 views

Forum|alt.badge.img+2

Hello,

I’m providing a free trial on my weekly plan and I want to check if a user is eligible for the trial. The goal is to display a text (e.g., “3 Day Free Trial”) based on eligibility.

How can I check if the user has already availed the free trial or not?

I tried this code, but it’s not working:

  val freeTrialText = if (pkg.storeProduct.subscriptionOptions?.defaultOffer?.freePhase != null) "3 Day Free Trial" else ""

println("3 day trial text: $freeTrialText")

This always returns empty.
On iOS, the payment popup correctly shows the 3-day free trial, but in the app it doesn’t reflect.

Any ideas on what I might be missing?

This post has been closed for comments

3 replies

alejandra-wetsch
RevenueCat Staff
Forum|alt.badge.img+6

Hey ​@Md-Atif

Thank you for reaching out!

In KMP, you can use the checkTrialOrIntroPriceEligibility method to determine if a user is eligible for a specific product or a set of products.

fun checkTrialOrIntroPriceEligibility(
products: List<StoreProduct>,
callback: (Map<StoreProduct, IntroEligibilityStatus>) -> Unit,
)

Below you can find all the available IntroEligibilityStatus and what each of them means:

  • ELIGIBLE: User can receive an intro/trial for this product
  • INELIGIBLE: User already used an intro in the group; show standard price
  • NO_INTRO_OFFER_EXISTS: Product has no intro/trial configured; show standard price
  • UNKNOWN: Platform/SDK couldn't determine; default to non-intro pricing

I hope this helps!


Forum|alt.badge.img+2
  • Author
  • Active Member
  • October 1, 2025

Hello ​@alejandra-wetsch,

Thank you for your reply! I had a follow-up question: how should we handle this scenario across both stores? The comments mention “iOS only. Android always returns IntroEligibilityStatus.UNKNOWN.”  but we’d like to implement handling for both platforms.

Do you have any suggestions on the best way to approach this?

 


alejandra-wetsch
RevenueCat Staff
Forum|alt.badge.img+6

Hey ​@Md-Atif

Thank you for following up! 

To handle eligibility for Android, you should check StoreProduct.subscriptionOptions.introOffer instead. If the result for a given product is null, the user is not eligible for a free trial, and therefore, the regular price should apply instead. You can read more about this in this documentation.

I hope this helps!