Create subscriptions with Stripe Billing
Software as a Service (SaaS) and marketplace businesses use Stripe Connect to route payments between themselves, customers, and connected accounts. You can use Connect to route payments or payouts and use Stripe Billing to support your recurring revenue model.
Use cases
You can create subscriptions for connect accounts, which supports several approaches for collecting payments. You can create subscriptions for your connected account’s customers using direct or destination charges, for your end customers to directly transact with your platform, and to charge your connected accounts a fee for using your platform.
The following use cases describe how to use Stripe Billing to create subscriptions from end customers to connected accounts, to bill platform end customers, and to bill connected accounts.
Use case | Description |
---|---|
Create subscriptions from the end customer to the connected account | Create subscriptions for end customers to your connected accounts, which supports several approaches for collecting payments. In this example, Prices reside on the connected account. |
Create subscriptions to bill platform end customers | Marketplaces can directly offer membership subscriptions without involving your connected account. In this example, Prices reside on the platform. |
Create subscriptions to bill connected accounts | Platforms can create subscriptions for their connected accounts. In this example, Prices reside on the platform. |
Restrictions
Using subscriptions with Connect has these restrictions:
- Your platform can’t update or cancel a subscription that it didn’t create.
- Your platform can’t add an
application_fee_amount
to an invoice that it didn’t create, nor to an invoice that contains invoice items the platform didn’t create. - Subscriptions aren’t automatically cancelled when you disconnect from the platform. You must cancel the subscription after disconnection. You can use webhooks to monitor transitions between subscription statuses.
Create subscriptions from the end customer to the connected account
If you’re building a platform, you can create subscriptions for your connected accounts’ customers, optionally taking a per-payment fee for your platform.
This example builds an online publishing platform that allows customers to subscribe to their favorite authors and pay them a monthly fee to receive premium blog posts from each author.
Prerequisites
Before you can create subscriptions for your customers or connected accounts, you must:
- Create a connected account for each person that receives money on your platform. In our online publishing example, a connected account represents an author.
- Create a pricing model. For this example, we create a flat-rate pricing model to charge customers a fee on a recurring basis, but per-seat and usage-based pricing are also supported.
- Create a customer for each person that subscribes to a connected account. In our online publishing example, you create a customer for each reader that subscribes to an author.
Decide between direct charges and destination charges
You can use either direct charges or destination charges to split a customer’s payment between the connected account and your platform.
If you want the connected account to be responsible for Stripe fees, refunds, and chargebacks, use direct charges. With this approach, customers won’t be aware of your platform’s existence because the author’s name, rather than your platform’s name, is shown on the statement descriptor. In our online publishing example, readers interact with authors directly.
Direct charges are also recommended if you’re using a Standard account.
If you want your platform to be responsible for Stripe fees, refunds, and chargebacks, use destination charges. In our online publishing example, customers subscribe to your publishing platform, not directly with specific authors.
Destination charges are also recommended if you’re using Express or Custom accounts.
For more information about the different types of Connect charges, see Charge types.
Use direct charges to create a subscription
To create a subscription with Charges associated to the connected account, make a create subscription call while authenticated as the connected account. Make sure to define the customer and the Price on the connected account.
Expand latest_invoice.payment_intent
to include the Payment Element, which is needed to confirm the payment. Learn more about Payment Elements.
For an end-to-end example of how to implement a subscription signup and payment flow in your application, see the subscriptions integration guide.
Use destination charges to create a subscription
To create a subscription with Charges associated to the platform and automatically create transfers to a connected account, make a create subscription call while providing the connected account ID as the transfer_data[destination]
value.
Expand latest_invoice.payment_intent
to include the Payment Element, which you need to confirm the payment. Learn more about Payment Elements.
You can optionally specify an application_fee_percent. Learn more about collecting fees.
Additional steps before you create a subscription
To create a destination charge, define both the customer and the price on the platform account. You must create the connected account’s token with the platform’s publishable key. The customer must exist within the platform account. When using destination charges, the platform is the merchant of record.
Create subscriptions to bill platform end customers
You can use Stripe Billing to create subscriptions for your end customers to directly transact with your platform without involving your connected accounts.
This example builds a marketplace that allows customers to order on-demand delivery from restaurants. This marketplace offers customers a premium monthly subscription that waives their delivery fees. Customers who subscribe to the premium offering pay the marketplace directly and don’t subscribe to any particular delivery service or restaurant.
Prerequisites
Before you create subscriptions for your customers, you must:
- Create a pricing model. For this example, we create a flat-rate pricing model to charge customers a fee on a recurring basis, but per-seat and usage-based pricing are also supported.
- Create a customer record for every customer you want to bill.
You can also create a connected account for each user that receives money from your marketplace. In our on-demand restaurant delivery example, a connected account is a restaurant or a delivery service. However, this step isn’t required for customers to subscribe to your marketplace directly.
Create a subscription
To create a subscription where your platform receives the funds, without any money going to connected accounts, follow the Subscriptions guide to create a subscription with Stripe Billing.
Create separate charges and transfers
If you want to manually transfer a portion of the funds that your platform receives to your connected accounts later, use separate charges and transfers to pay out funds to one or more connected accounts. In our on-demand restaurant delivery example, you can use separate charges and transfers to pay out an affiliate fee to a delivery driver or restaurant who refers a customer to subscribe to the premium delivery service.
Create subscriptions to bill connected accounts
You can use Stripe Billing to create subscriptions to charge your connected accounts a fee for using your platform.
This example builds a gym management software platform that allows gym businesses to pay a monthly fee to use the software to manage scheduling and appointments for classes. The gym businesses pay the subscription fee, not the gym patrons.
The gym management software also facilitates one-time payments between the gym patron and gym business for each class that the gym patron enrolls in. The monthly subscription is between the connected account and the platform, which doesn’t involve the gym patron in the transaction.
In the diagram above, the gym business is the connected account and the gym patron is the end customer.
Prerequisites
Before you create subscriptions for your customers or connected accounts, you must:
- Create a connected account for each user that receives money on your platform. In this example, the connected account is the gym business.
- Create a pricing model. For this example, we create a flat-rate pricing model to charge customers a fee on a recurring basis, but per-seat and usage-based pricing are also supported.
- Create a customer on the platform with the intended payment method for every connected account you want to bill. In the gym management software example, you create a customer for each gym business:
Create a Customer object to represent the connected account
If your connected accounts use Stripe to process payments for their end customers, they might have already created a Customer object for each end customer.
To successfully create a subscription for the connected account to pay a recurring fee to the platform, you must create a separate Customer object to represent the connected account.
In the gym example, the gym business uses Stripe to process one-time payments for its gym patrons. They already created a Customer object for each gym patron, but you need to create a different Customer object to represent the gym business itself. Create only one Customer to represent each business entity and don’t create a Customer to represent each owner, manager, or operator of the business.
Create a subscription for the connected account
To create a subscription where your platform receives the funds from your connected accounts, follow the Subscriptions guide to create a subscription with Stripe Billing. The Customer object involved in the transaction represents the connected account, not the end customer. In our gym example, the CUSTOMER_ID
represents the gym business, not the gym patron.
Test your integrationRecommended
After you create your subscription, thoroughly test your integration before you expose it to customers or use it for any live activity. Learn more about testing Stripe Billing.
Additional options
After you create your subscription, you can specify an application_fee_percent, set up the customer portal, and monitor subscriptions with webhooks, in addition to other options.