Migrating from StoreKit 1 to StoreKit 2

Now that Apple has deprecated StoreKit 1

Charlie Chapman
Nacho Soto
PublishedLast updated

StoreKit 1 vs. StoreKit 2

StoreKit has been with us since iPhone OS 3.0 launched in 2009. It was not without its flaws, and developers had to battle implementation and upkeep for over 12 years.

At WWDC 2021, we saw the introduction of the new StoreKit 2: a new Swift-only framework with modern async APIs. Since then, the RevenueCat team has been hard at work to support the new APIs. 

Apple officially deprecated the StoreKit 1 APIs at WWDC 2024, which they’ve also renamed to “original API for in-app purchase”. While these APIs will still work for now, Apple has clearly signaled that it’s time to switch to StoreKit 2 APIs. New features and updates going forward will be for StoreKit 2 only.

Migrate to StoreKit 2 with the RevenueCat SDK

RevenueCat is a powerful and reliable in-app purchase server and client SDK that makes it easy to build, analyze, and grow your subscriber base whether you’re just starting out or already have millions of customers.

If you’re using the RevenueCat SDK, migrating to StoreKit 2 is as easy as updating to the latest version of SDK! Our engineers spent the last few years building and testing StoreKit 2 so you don’t have to.

There are a few caveats to keep in mind which you can find outlined in our SDK launch post and our migration guide.

Migrating manually to StoreKit 2

Migrating your existing StoreKit 1 implementation to StoreKit 2 without RevenueCat is, obviously, a lot more involved. 

Replace Receipt

With StoreKit 2, Apple replaced the old receipt with a few new entities such as Transaction and RenewalInfo, that contain that same data signed in a JSON Web Signature (JWS) format. You’ll need to migrate all of your code parsing data out of the old receipt to use these new entities.

Use App Store Server API on your server

On your backend, you’ll need to use the new App Store Server API for verifying Transaction and auto-renewable subscription status, refund information, order information lookups, and other customer in-app purchase history information.

Backwards compatibility

An important note is that StoreKit 2 is only compatible with iOS 15 and later. Also, there were a few APIs that weren’t added until iOS 16 such as originalPurchaseDate that are important for apps that migrated from Paid Up Front to Subscription business models and want to grandfather features for existing paid users.

If your app supports iOS 15 or earlier, you will need to make sure your app still uses the old StoreKit 1 APIs on devices running on those older versions of iOS. Note that if you’re using the RevenueCat SDK we will handle all of this for you.

More resources

We at RevenueCat would obviously love you to take this opportunity to consider using our SDK to make this switch much easier. But we’ve got your back either way! For a comprehensive guide to implementing StoreKit 2 for your app, check out our StoreKit 2 Tutorial.

For help migrating your existing app to RevenueCat, check out our exceptional documentation or request a migration consultant for building out a custom migration plan.

You might also like

Share this post

Want to see how RevenueCat can help?

RevenueCat enables us to have one single source of truth for subscriptions and revenue data.

Olivier Lemarié, PhotoroomOlivier Lemarié, Photoroom
Read Case Study