Skip to main content

After building your app in Rork, use this documentation to setup a paywall with Revenuecat.

Summary

This tutorial will guide you through taking your Rork project and adding a Revenucat paywall to it, deploying it to the app store, and verifying it works Requirements
  • Apple AppStore Developer Account
  • RevenueCat Account
  • AI-Powered IDE (Windsurf/Cursor/Copilot/etc)
  • Physical iPhone to Test
Table of Contents

1. Sync your project to Git

Press the Integrations button at the top right inside of your Rork project. Press Create Repository and setup a new repo connected to your Github account. Screenshot 2025-09-19 at 11.32.58 AM (1).png The project will automatically sync your most up to date changes to that Github repository making it the source of truth.

2. Open the Git repo locally in your IDE

Use the instructions inside of your Github repository or your IDE to locally connect your repo. Screenshot 2025-09-19 at 11.34.57 AM (1).png

Install project packages

bun install

3. Setup local development builds

In order for us to test using a local device, we need to initialize the Expo project and setup development build. Lets first initialize Expo. If this is your first time using Expo, you will be asked to create an account and setup the project. The default yes to the questions are fine.

Install EAS + Login

npm install -g eas-cli && eas login

Initialize Expo

eas init
Now we need to setup Expo Development Builds because RevenueCat will not work inside of the ExpoGo/Rork app. It changes binary code for your app, so we are going to need to create development builds to run the app. https://docs.expo.dev/develop/development-builds/create-a-build/

Install expo-dev-client

npx expo install expo-dev-client
We are now ready to test a local development build through Expo. This will setup our provisional certificates needed as well from Appstore connect. This will allow your iPhone to download and test local builds. We can also make sure the app is functionally working as we expect it too before we setup paywall.

Deploy a Development Build

eas build --platform ios --profile development
You will be given a link so you can check the build process on the Expo website. This process should take 5-10 minutes depending on how big your app is. After it finishes building, you will be given a QR code inside of the terminal. If you do not see the QR code, you can press Download button on that the build page on Expo website to show the QR code. Open the QR on your phone that is provisioned to download apps.

Test your Development Build

Development builds are considered development because they rely on you to run a local Expo server. It lets you update code in real time with the build that is in your phone. The only reason to deploy the build again is not for basic code changes, but if you change the binary (package installs that change native code).

Run Expo locally

bun start
A QR code should show up and you should see it say “Development build” Screenshot 2025-09-19 at 11.55.08 AM (1).png Scan the QR code with your phone and it will open your app. Test and make sure everything is working as expected. If not, use the AI chat to fix your issues.

4. Initial RevenueCat Project Setup

http://revenuecat.com/ RevenueCat helps you build & deploy paywalls without coding. You can even A/B test different paywalls here. RevenuCat makes it really convenient to gate features in your app and manage user payments. Create a RevenueCat account and create a project Screenshot 2025-09-22 at 1.17.09 PM (1).png

5. Deploy to App Store Connect

Before we move onto the next part, we need to initialize our project inside of AppStore Connect. The fastest and most convenient way to do this is to just run a production build.

Run the production build deployment command

eas build --platform ios --profile production
After it finishes building, we need to submit it to the Apple server. Because it will be your first time doing it, there will be some additional questions Expo asks to properly setup the app. They should easily walk you through it.

Submit to AppStoreConnect

eas submit --platform ios
Screenshot 2025-09-22 at 1.41.10 PM (1).png Select recent builds from EAS and choose the most recent one You should now see your App inside of AppStore Connect under your Apps.

6. Connect AppStoreConnect to RevenueCat

Add an app config for IOS App Store in the Apps & providers section of your app settings. image (27).png

Now connect Apple Bundle ID & Auth Keys

For iOS Bundle ID and Android Bundle ID, it is important that the same bundle ID that is set in your [app.json] file is also set here. You can find the IDs in the sections as highlighted in the image below: (ios.bundleIdentifier) and (android.package) Screenshot 2025-09-19 at 12.03.03 PM (1).png

Create an In-App Purchase Key inside of App Store Connect → Users & Access → Integrations → In-App Purchase (CLICK HERE FOR IT)

It will also download a .p8 file after you create the key. Do not lose that file and secure it. Enter your bundle id, key id, and issuer id into this. Upload the p8 file you just downloaded into it as well. Screenshot 2025-09-22 at 11.27.41 AM (1).png

Create an App Store Connect API key inside of App Store Connect → Integrations → In-App Purchase (CLICK HERE FOR IT)

Same situation. Allow for App Manager/Admin permissions and save. It will download another p8 file. Secure that and upload that one in this section too. Screenshot 2025-09-22 at 2.35.54 PM (1).png

Go to this section of the page with and copy that URL

Screenshot 2025-09-22 at 2.35.46 PM (1).png

Place it inside of your App Store Server NotificationsProduction and Sandbox URLS which can be found in App Store Dashboard for your App under General → App Information

Use the same link for both production and sandbox URLs. Screenshot 2025-09-22 at 2.37.19 PM (1).png

7. Create your Products in App Store Connect

Now we need to establish the different in-app purchases the user will be able to do. Each one of these is considered a product. We need to set up the product’s name, ID, price, duration, and trial period. It is important that we have some naming convention for this. We will need to use these exact same names when we create our products in App Store Connect later in the tutorial. For this tutorial, we will create 3 products. Our app is a single “pro” subscription, but we will have 3 ways one can buy it. One is a 5/weekplan.Anotherisa5/week plan. Another is a 10/month plan. And finally, a $100/year plan. The naming convention for the IDs will be like so: ios_appname_1m ← month plan ios_appname_7d ← week plan ios_appname_1y ← year plan Go to subscriptions page in your Apps dashboard within App Store connect.

Create a new Subscription Group

We only need one since there is only one type of subscription (Membership vs No Membership). Name it Premium or Pro. Screenshot 2025-09-19 at 2.29.06 PM (1).png

Create 3 product subscriptions and label them correctly

Screenshot 2025-09-19 at 2.32.41 PM (1).png After pressing Create, set the Subscription Duration, the Availability, the Pricing, and the Localization (which is just another way to label the Plan). I would also upload a screenshot of your apps functionality from the development testing to the screenshot section and write a comment about what the plan does for the app. Screenshot 2025-09-19 at 2.34.32 PM (1).png

Setup Localization for the Subscription Group itself

and you should be ready to go Screenshot 2025-09-19 at 2.34.51 PM (1).png

8. Create Entitlements + Import Products to RevenueCat

Now we need to create an entitlement inside of RevenueCat. Think of an entitlement as a specific VIP package that different member types get when they purchase in your app. For simplicity sake, we only setup one subscription group, so label the entitlement the same thing. Make note of this entitlement when we set it up later in the IDE. Screenshot 2025-09-22 at 11.28.40 AM (2).png

Now RevenueCat makes it really easy to import the products you just made in AppStoreConnect

Go to Product Catalog → New Product → Choose your App Store App Screenshot 2025-09-22 at 2.42.27 PM (2).png

Press Import Products Automatically and you should see the three products you made in AppStore Connect. Select them all and add them in. You will see an option to add entitlements for each one. Add the entitlement you created earlier.

Screenshot 2025-09-22 at 2.45.01 PM (1).png

9. Creating the Offering + Paywall

Offerings are the different subscription periods that are offered. You may have some exclusive deals for 3 month plans and other creative payment plan options, so experiment here over time.

Create a new offering

Screenshot 2025-09-22 at 2.46.58 PM (1).png

Add all of your products with the appropriate duration

Screenshot 2025-09-22 at 2.47.13 PM (1).png Save with the name “default” or whatever you prefer. RevenueCat has a ton of templates for paywalls. You can use those and edit them to your liking in the paywall editor. RevenueCats paywall editor allows you to remotely update paywalls so you can optimize your paywalls for higher conversion rates. Go to the Paywall page and create a new one. Choose a paywall template that fits your aesthetic. Preferably one that also had 2-3 buttons already. This will open the paywall editor.

Choose your Paywall Template

Select the offering we just made as well when creating the paywall. Screenshot 2025-09-22 at 2.45.57 PM (1).png

Connect your Products to your New Paywall

Once the editor opens, you’ll notice that the prices are incorrect. We need to connect the real products you setup earlier to it. Screenshot 2025-09-22 at 11.36.50 AM (1).png

Look for the package layers on the left component stack and update them using the package properties settings on the right accordingly.

Screenshot 2025-09-22 at 1.45.25 PM (1).png

Update the text within the pricing blocks to fit your offerings.

Screenshot 2025-09-22 at 11.41.17 AM (1).png

Update the text on the Paywall so it fits your App and finally press Publish

Screenshot 2025-09-22 at 2.52.33 PM (1).png

10. Install RevenueCat into the App

https://www.revenuecat.com/docs/getting-started/installation/expo We need to install the RevenueCat packages into our Expo app. Go back to your IDE and run these commands to install RevenueCat.

Install RevenueCat packages in your IDE

npx expo install react-native-purchases react-native-purchases-ui

Grab The API Key

In your RevenueCat project, click API Keys from the panel on the bottom left, find App Store Public API Key and copy your Public API Key: Screenshot 2025-09-22 at 2.56.23 PM (1).png

Initialize RevenueCat in your app

To use the RevenueCat SDK, you need to run a command at the root of your project.

Edit the file app/layout.tsx

In the AI chat of your IDE, paste this prompt, but update the API key to be the we copied right above.
Chat, please initialize RevenueCat in our project. Here is the command you should run. We are only
focusing on iOS for now.

import { Platform, useEffect } from 'react-native';
import { useEffect } from 'react';
import Purchases, { LOG_LEVEL } from 'react-native-purchases';

//...

export default function App() {

  useEffect(() => {
    Purchases.setLogLevel(LOG_LEVEL.VERBOSE);

    if (Platform.OS === 'ios') {
       Purchases.configure({apiKey: 'YOUR_ACTUAL_KEY_HERE'});
    }

  }, []);
}
Make sure to add your REAL KEY in these lines: Purchases.configure({apiKey: 'YOUR_ACTUAL_KEY_HERE'});

11. New Deployment for RevenueCat Package

Before we move onto the next part, we should run a new development build and get it on our phone.

In your app.json file, please bump your Version number up to 1.0.1

Then run the development build deployment command

eas build --platform ios --profile development
After it finishes building, install the new version onto your phone using the QR code provided.

Run your development server

bun start
Scan the QR code and get into the app again. Nothing should have changed and everything should work fine.

12. Add Trigger & Feature Gating in App

To make it easy for us, we will be using the AI chat inside of the IDE to set this up. Once you’ve done so, you can say the following prompt to add the paywall + feature gating. Please update the text in quotes to your actual trigger placement and feature gate. Make sure it fits the functionality of YOUR app.
We are using RevenueCat for our paywall in app.
How it works: RevenueCat will check for this command const customerInfo = await Purchases.getCustomerInfo(); (typeof customerInfo.entitlements.active[”Pro”] !== “undefined”) IF the customer has an activeEntitlement with the label “Pro”, they are considered Pro membership and **get unlimited token generations for images. Otherwise, show them an Upgrade to Pro button and if they click it or try to generate an image, show the paywall as this example shows it:** Copy and paste this into your AI editor and update the Entitlements (Pro/Premium), Trigger Placement, and What Functionality it Gates and Should Trigger For The AI should update your project and after restarting the app on your phone, you should be able to test it. Try to do the feature that is now gated and your paywall should pop up. Your paywall make look something like this: This is looking great! It got the products that we setup and you should be able to do a fake purchase and see the conditional membership work! Working Rc Pn Our app is working properly! It gated the function and when you try it after, it works! Lets gooo!

13. Deploy to Production

Run the following command for a production deployment

eas build --platform ios --profile production
Then run eas submit to fully submit it

Submit to AppStoreConnect

eas submit --platform ios
Select recent builds from EAS and choose the most recent one You should now see your build show up on Testflight ready to test and submit!

Conclusion: A Working Paywall + Testflight Production App

At this point, we are officially done setting up the paywall! Check your email because you were invited by Testflight to download your apps production build inside of the Testflight app. Do so and then try out the paywall. It should show the real prices and in testflight, it will mock the purchase so you can test the gating and see it work properly! A long process but you finally did it! Congrats!