Changing the Subscription Billing Cycle

    Learn how to change the date when your customers are billed for a subscription.

    A subscription’s billing date is determined by:

    • When the subscription is created
    • Its billing interval

    A customer subscribed to a monthly plan on the 2nd will always be billed on the 2nd. A different customer subscribed to that same plan starting on the 15th will always be billed on the 15th.

    You can change when an existing subscription is billed by introducing a trial period. Although trial periods are normally used at the start of a subscription, applying them during a subscription is allowed.

    For example, if it is May 15th and a customer has an active subscription set to bill next on May 23rd, but you introduce a trial period until June 1st:

    • The customer will not be billed on May 23rd
    • The customer will be billed next on June 1st, and be subsequently billed on the first of the month thereafter

    You can change a subscription’s billing cycle via the API or the Dashboard, but you need to consider proration first.

    Handling prorations

    Stripe bills subscriptions in advance: the customer paid for the current billing interval via the previous invoice. As a trial period is by definition a free period on a subscription, introducing a trial to an existing, paid subscription results in a proration. The customer is credited for the period they’ve already paid for that is now being called “free”.

    When moving the billing cycle, this use of a trial period is not a real free trial in that the user is presumably continuing full access to your service or product. For that reason, it’s important that you disable proration when moving the billing cycle.

    Changing the billing cycle via the API

    To add a trial period to an existing subscription, perform an update subscription call, providing a trial_end value:

    curl https://api.stripe.com/v1/subscriptions/sub_49ty4767H20z6a \
       -u sk_test_BQokikJOvBiI2HlWgH4olfQ2: \
       -d trial_end=1509770859 \
       -d prorate=false
    
    # Set your secret key: remember to change this to your live secret key in production
    # See your keys here: https://dashboard.stripe.com/account/apikeys
    Stripe.api_key = "sk_test_BQokikJOvBiI2HlWgH4olfQ2"
    
    subscription = Stripe::Subscription.retrieve("sub_49ty4767H20z6a")
    subscription.trial_end = 1509770859
    subscription.prorate = false
    subscription.save
    
    # Set your secret key: remember to change this to your live secret key in production
    # See your keys here: https://dashboard.stripe.com/account/apikeys
    stripe.api_key = "sk_test_BQokikJOvBiI2HlWgH4olfQ2"
    
    subscription = stripe.Subscription.retrieve("sub_49ty4767H20z6a")
    subscription.trial_end = 1509770859
    subscription.prorate = false
    subscription.save()
    
    // Set your secret key: remember to change this to your live secret key in production
    // See your keys here: https://dashboard.stripe.com/account/apikeys
    \Stripe\Stripe::setApiKey("sk_test_BQokikJOvBiI2HlWgH4olfQ2");
    
    $subscription = \Stripe\Subscription::retrieve("sub_49ty4767H20z6a");
    $subscription->trial_end = 1509770859;
    $subscription->prorate = false;
    $subscription->save();
    
    // Set your secret key: remember to change this to your live secret key in production
    // See your keys here: https://dashboard.stripe.com/account/apikeys
    Stripe.apiKey = "sk_test_BQokikJOvBiI2HlWgH4olfQ2";
    
    Subscription subscription = Subscription.retrieve("sub_49ty4767H20z6a");
    
    Map<String, Object> params = new HashMap<String, Object>();
    params.put("trial_end", 1509770859);
    params.put("prorate", false);
    
    subscription.update(params);
    
    // Set your secret key: remember to change this to your live secret key in production
    // See your keys here: https://dashboard.stripe.com/account/apikeys
    var stripe = require("stripe")("sk_test_BQokikJOvBiI2HlWgH4olfQ2");
    
    stripe.subscriptions.update("sub_49ty4767H20z6a", {
        trial_end: 1509770859,
        prorate: false,
      }, function(err, subscription) {
        // asynchronously called
      }
    );
    
    // Set your secret key: remember to change this to your live secret key in production
    // See your keys here: https://dashboard.stripe.com/account/apikeys
    stripe.Key = "sk_test_BQokikJOvBiI2HlWgH4olfQ2"
    
    params := &stripe.SubParams{
      TrialEnd: 1509770859,
      NoProrate: true,
    }
    subscription, err := sub.Update("sub_49ty4767H20z6a", params)
    

    As a reminder, you probably want to also set prorate to false—as in that code—so the customer is not credited for any previously paid but unused time.

    Changing the billing cycle via the Dashboard

    To add a trial period to an existing subscription via the Dashboard:

    1. Find the subscription you want to change.
    2. Click Edit details.
    3. Set Trial end to the date you want billing to resume.
    4. Uncheck Prorate (per the above discussion, this is likely what you want).
    5. Click Done.

    Next steps

    Congrats! You know how to change a subscription's billing cycle. Some resources you might want to see next: