We are using Stripe payment processing for our customer\'s subscriptions. When users change plans, we want them to be charged immediately for the prorated difference. Stripe
You can use billing_cycle_anchor
set to now
when updating a subscription to force it to change the billing cycle and thus always charge the customer immediately. Personally I think this makes a lot more sense. Also this works well with prorating.
await stripe.subscriptions.update(subscription.id, {
billing_cycle_anchor: 'now',
items: [{ id: itemId, plan: planId }]
});
https://stripe.com/docs/billing/subscriptions/billing-cycle#changing