Back to Blog
MonetizationAug 28, 2026 9 min

Monetizing Your Shopify App: A Practical Guide to the Billing API

The Shopify Billing API is the only way to charge merchants without handling credit cards yourself. Here's how to implement it correctly — with real code patterns.


Monetization is the difference between a hobby project and a sustainable business. Shopify's Billing API lets you charge merchants through their regular Shopify invoice — no credit card forms, no PCI compliance, no payment gateway integration. The merchant sees the charge on their monthly Shopify bill, and Shopify handles the collection. Let's break down how to implement it.

Recurring Application Charges

The most common monetization model: a monthly subscription. You create a `appSubscriptionCreate` mutation via the GraphQL Admin API with a name, price, return URL, and test flag. Shopify presents the merchant with a confirmation page. Once they approve, they're redirected to your return URL, and you activate the subscription. The key fields: `lineItems` defines what you're charging for (you can have multiple tiers), `returnUrl` is where the merchant lands after approval, and `trialDays` lets you offer a free trial period.

Tiered Pricing: Free / Pro / Business

Most successful Shopify apps offer multiple tiers. A common pattern: Free tier with limited features (great for getting installs and reviews), Pro tier at $9.99–$29.99/month for most merchants, and Business/Enterprise tier at $49.99+ for high-volume stores. The Billing API supports this natively — you create separate subscription plans and check the merchant's active subscription to determine feature access. In your app, you'd check the subscription status on every admin page load and gate features accordingly.

One-Time Charges

Not everything fits a subscription model. For setup fees, premium add-ons, or usage-based charges, the `appPurchaseOneTimeCreate` mutation creates a single charge. The flow is identical to recurring charges: create the charge, redirect the merchant for approval, then activate. One-time charges are useful for things like premium theme templates, data migration services, or API call overages.

Usage-Based Billing

For apps that charge based on usage (e.g., per email sent, per API call), Shopify offers usage billing. You create a recurring subscription with `usageTerms` defining the pricing model, then report usage via `appSubscriptionUsageRecordCreate`. Shopify aggregates the usage and bills the merchant accordingly. This is ideal for apps with variable costs — you don't pay for unused capacity, and merchants pay for what they actually use.

The Webhook You Can't Skip

When a merchant's payment fails or they cancel their subscription, Shopify fires the `app_subscriptions/update` webhook. You must handle this to downgrade the merchant's access or disable paid features. Ignoring this webhook means merchants keep accessing paid features after canceling — a fast track to chargebacks and App Store removal.

Testing Your Billing Integration

Shopify provides a test mode for billing. When your app is installed on a development store, all charges are simulated — no real money changes hands. Set `test: true` in your charge mutations during development. Before submitting to the App Store, test the full flow: install → free trial → upgrade to Pro → cancel → reinstall. This catches edge cases like merchants who subscribe, cancel mid-cycle, then resubscribe.