Ben Dodson

Freelance iOS, macOS, Apple Watch, and Apple TV Developer

Using Stripe for In-App Purchases

When I launched Unique Items for WallaBee a few years ago, I didn’t completely grasp how popular they’d be. Within a few weeks, we had hundreds of orders (all processed through PayPal) and ended up with a year-long backlog which has only now been cleared. In anticipation of allowing players to commission these items again, I’ve been looking at payment providers and settled on Stripe now that they’ve fully launched in the UK. After having a quick look at their docs, I realised it was going to be insanely easy to integrate their SDK into a website and that is when I started thinking about using them for In-App Purchases (IAP).

Apple allow developers to use their StoreKit to create In-App Purchases but it comes at a steep price: 30% of all sales. For that 30%, you get simplicity and ease of use for the customer who can just tap a button, type in their iTunes password, and buy any digital content upto $999. This is what we’ve been using with WallaBee for over 3 years but with several issues arising lately1 I thought I might have a go at creating a way for players to buy our in-game currency and lock mechanisms on our website. After a couple of hours, I had a fully functioning site which does just that with full integration with Stripe. Players log in and then click a button to begin using Checkout, Stripe’s own JavaScript based checkout system which will either operate in an overlay on desktop or open in a new window on mobile. The card form is incredibly simple (and no doubt well tested) and allows customers to pay within seconds. It also has the ability to remember a customer so later purchases will be quicker.

The end result so far has been that 50% of our players have chosen to purchase online2 which adds up to a sizeable increase in income as Stripe charge roughly 4-5% once currency conversion (if necessary) is taken into account. Another nice benefit is that Stripe pay you daily for transactions 7 days ago - that means the sales from today will be in our account next week whereas with Apple we have to wait as long as 2 months for a transaction to be paid. We also get more control over the refund process as at the moment anybody can ask Apple for a refund and will usually get it - we don’t get notified when that happens so it means some players can get purchases for free3.

The only issue with this is that it has to be completely confined to the web and we’re not allowed to add a buy button or similar to the app to direct people to the purchase site as per rule 11.13 of the App Store Guidelines:

11.13: Apps that link to external mechanisms for purchases or subscriptions to be used in the App, such as a “buy” button that goes to a web site to purchase a digital book, will be rejected

It is permissable to sell content for your apps online, you’re just not allowed to have any buttons linking to the site within the app. This means that we’ll need to keep both the Apple IAP system and our Stripe online system running separately but so far the results look good. If you have some form of gaming app that relies on IAP, you’d be crazy not to look at doing something similar.

  1. It seems to be that if Apple changes it’s ToS, players who make a purchase are then asked to verify their agreement and end up getting charged without having the charge hit my servers so they end up getting nothing. There is also a complex dance to verify everything with a successful purchase going to my server, my server verifying with Apple, Apple replying that it’s all ok, and then me adding the purchase to the database - if a connection is dropped at any point, then customer ends up with nothing. ↩︎

  2. No doubt helped by the 5% discount we added whilst trialling it. ↩︎

  3. I’ve not seen many instances of this but it has happened and there isn’t anything we can do about it as Apple don’t say who has been refunded, just that a refund has occurred. ↩︎

Working out with Apple Watch » « iTunes Artwork Finder Source Code

Want to keep up to date? Sign up to my free newsletter which will give you exclusive updates on all of my projects along with early access to future apps.