◉RORK LABJP
●ARCHIVE — Since 11/22 you can archive a Rork project instead of deleting it, and bring it back from Archived●PLAY FIX — Fixed: Expo apps built for Google Play losing their Rork AI key, which broke AI features●SONNET 4.5 — Sonnet 4.5 retires from the Claude API on 11/30, 7 days left. Check which model your app calls●SPLASH — Expo users report apps stuck on the splash screen after rolling back to an earlier update●NEW — New: Three clues to check before replying to a "stuck on the splash screen" review●2.5 ROUTE — From 12/1, Gemini 2.5 requests reroute to newer models at new rates. 8 days left●ARCHIVE — Since 11/22 you can archive a Rork project instead of deleting it, and bring it back from Archived●PLAY FIX — Fixed: Expo apps built for Google Play losing their Rork AI key, which broke AI features●SONNET 4.5 — Sonnet 4.5 retires from the Claude API on 11/30, 7 days left. Check which model your app calls●SPLASH — Expo users report apps stuck on the splash screen after rolling back to an earlier update●NEW — New: Three clues to check before replying to a "stuck on the splash screen" review●2.5 ROUTE — From 12/1, Gemini 2.5 requests reroute to newer models at new rates. 8 days left
Articles/Dev Tools
⬡ Dev Tools/2026-06-25Advanced

Why Paying Members See a Paywall in Airplane Mode — Keeping RevenueCat Entitlements Alive Offline

Open the app on a weak connection and a paying subscriber sees a paywall flash for a second. Here is how RevenueCat's customerInfo wavers on an offline launch, and a cache design that keeps entitlements valid with a trust window — written as working code for an Expo app.

Rork621RevenueCat30Expo237Subscriptions17Offline3

✦ Premium Article

A reader on a subway once told me they were paying for the app yet saw the purchase screen "just for a moment" every time they opened it. I switched my own app to airplane mode to reproduce it, and sure enough, for about a second after launch a paywall flickered on top of the premium content. The money had been paid, and the app still showed it.

The cause was not the entitlement logic itself. It was that the network round-trip needed to confirm membership had not finished yet. RevenueCat is convenient, but there is always a moment when it goes over the network to ask "is this person a member?" When that moment is offline, the app passes through a state of "not yet confirmed as a member." This article builds the cache layer that keeps a paying member from being locked out during that moment, as an implementation for an Expo (React Native) app.

Why customerInfo wavers on an offline launch

Purchases.getCustomerInfo() in react-native-purchases returns a local cache first and reconciles with the server behind it. The easy misunderstanding here is that the cache is not trusted forever. After a certain interval the SDK treats the cache as stale and decides it needs the network. On a fully offline cold start, that refetch fails and entitlements.active can come back close to empty.

So the problem happens in two stages. If the SDK's cache is still warm you are fine, but if you open the app for the first time in days, or the OS has fully killed the process, there is no cache to lean on. If you have naively written "empty active means not a member," a paying reader gets bounced back to the paywall.

I run about six wallpaper apps on my own, and people do not open them only on home Wi-Fi. Commuter trains, planes, the mountains, an airport abroad. When you judge entitlement on the assumption that the network is reachable, the person who quietly leaves first is the paying member you should value most.

Hold your own "last known good"

Separate from RevenueCat's cache, store on the app side the fact of "the last time we definitely confirmed membership." The key is that what you store is not a boolean but an expiry — until when it is valid. A subscription always has an expirationDate. Save that, and even offline you can reason that "they should still be a member until that date."

// entitlementCache.ts
import AsyncStorage from "@react-native-async-storage/async-storage";
 
const KEY = "entitlement.lastKnownGood.v1";
 
export type CachedEntitlement = {
  // Treat as a member offline until this date (ISO string)
  activeUntil: string | null;
  // Wall clock at write time, for detecting clock rollback
  savedAt: string;
};
 
// Call only when entitlement was confirmed over the network
export async function writeLastKnownGood(
  activeUntil: string | null
): Promise<void> {
  const payload: CachedEntitlement = {
    activeUntil,
    savedAt: new Date().toISOString(),
  };
  await AsyncStorage.setItem(KEY, JSON.stringify(payload));
}
 
export async function readLastKnownGood(): Promise<CachedEntitlement | null> {
  const raw = await AsyncStorage.getItem(KEY);
  if (!raw) return null;
  try {
    return JSON.parse(raw) as CachedEntitlement;
  } catch {
    // Swallow a corrupted cache and fall back to network judgment
    await AsyncStorage.removeItem(KEY);
    return null;
  }
}

Wrapping JSON.parse in a try is deliberate. Persisted data does occasionally get corrupted — for instance when the app is killed mid-write. If JSON.parse throws on a corrupted cache, that can become a launch-time crash. Write the escape hatch from the start: if the read is corrupted, drop it and go back to network judgment.

✦

Thank you for reading this far.

Continue Reading

What follows includes implementation code, benchmarks, and practical content we hope you'll find useful. This site runs without ads — server and development costs are supported entirely by members like you. If it's been helpful, we'd be truly grateful for your support.

WHAT YOU'LL LEARN
✦If paying members were seeing a paywall on weak connections, you'll get an implementation that holds their access even on an offline launch
✦You'll understand how to cache customerInfo and where to anchor the trust window, so access never lingers after a cancellation
✦You'll build the cold-start first paint as three stages — loading, cache, network reconcile — for a paywall that never flickers
Secure payment via Stripe · Cancel anytime
✦

Unlock This Article

Get full access to the rest of this article. Buy once, read anytime. This site is ad-free — your support goes directly toward keeping it running.

or
Unlock all articles with Membership →
Share

Thank You for Reading

Rork Lab is ad-free, supported entirely by members like you. We publish practical guides daily with implementation code, benchmarks, and production-ready patterns. If you've found it useful, we'd love to have you on board.

  • ✦Copy-paste ready implementation code
  • ✦New advanced guides published daily
  • ✦$5/mo or $10 for lifetime access
View Membership →

Related Articles

⬡ Dev Tools2026-11-19
New Wallpapers Showed Up Everywhere Except the Filters: Ship the Count and the Category Lists Together
I added 67 wallpapers in one batch. They appeared in the full list and in New, but not under a single category filter, because I had raised the ID limit and forgotten to ship the category lists. Here is a pre-bump check, a client-side way to spot silent fallbacks in an Expo app, and a post-release count against the origin.
⬡ Dev Tools2026-10-30
It runs in development but the iOS Release build dies on launch — checking whether a missing scheme is the cause
In an expo-router app, an app.json with no scheme can crash only the iOS Release build at launch. Why Debug and Android survive, the two ways to fix it, how to think about leaving the scheme out on purpose, and a pre-submission check.
⬡ Dev Tools2026-10-15
When EXPO_PUBLIC_ Values Read Fine in Dev but Come Back undefined in Production: Telling the Spellings Apart
The API URL reads fine while developing and turns undefined once the app is built. The cause was how process.env was written. I lined up babel-preset-expo's output for dev and production and tabulated which spellings get replaced and which are left behind.