Skip to main content

Trends, tech news, and tool comparisons.

How to add a free trial to a SaaS with Stripe

· 6 min read
Dealpuffin
Proof points and live coupons for early adopters

To add a free trial with Stripe, create a Checkout Session in subscription mode and pass subscription_data.trial_period_days, for example 14. The customer signs up without paying, and Stripe bills the first invoice when the trial ends. The choices that matter are whether to collect a card up front, what happens if no card arrives, and how you warn people before the first charge.

Stripe details below come from its documentation, read on 18 November 2026.

Decide: card up front or not​

By default a Checkout Session collects a payment method even though nothing is charged. Stripe's free trial guide shows how to skip it with payment_method_collection=if_required. The trade-off is familiar. Asking for a card filters for intent and makes conversion automatic, while skipping it lowers the barrier to starting. Free trial versus freemium for early-stage SaaS covers that decision. This post assumes you have made it.

Step 1: create the Checkout Session with a trial​

Pass these parameters when you create the session:

  1. mode=subscription
  2. A line item with your recurring Price ID and quantity 1
  3. subscription_data[trial_period_days]=14

You can use trial_end, a Unix timestamp, instead of a number of days. Stripe's docs give the maximum trial length as 2 years (730 days) and note that most businesses use shorter ones, such as 30 days. Longer trials have two known problems: payment methods may expire before the first charge, and conversion rates tend to be lower.

Step 2: choose what happens without a card​

If you collect no payment method, tell Stripe what to do when the trial ends. Set subscription_data[trial_settings][end_behavior][missing_payment_method] to one of two values:

  • cancel ends the subscription immediately when the trial ends without a card. The customer can start a new subscription later.
  • pause keeps the subscription, stops it cycling and generates no invoices until you resume it. A paused subscription can stay that way indefinitely, and the customer can resume it from the customer portal by adding a payment method.

Pause is gentler and preserves their data and history. Cancel is simpler to reason about. Whichever you pick, your app must restrict access when it gets the matching event, customer.subscription.deleted or customer.subscription.paused.

Step 3: tell people before the first charge​

Stripe can send its own reminder, and it can also fire an event so you send yours. From the trials reference:

  • The customer.subscription.trial_will_end event fires according to the Trial ending events setting in the Dashboard, which defaults to 3 days before the trial ends. If the trial is shorter than that interval, it fires immediately.
  • Stripe-hosted reminder emails go out 7 days before the trial ends.
  • Stripe does not send trial reminder emails in a sandbox.

Use the event to email the customer with the price, the date and a link to add or update a card. The customer portal can host that step. Stripe also has a page on compliance requirements for trials and promotions that card networks expect you to follow, so read it before launch. If the first charge then fails, how to handle failed payments in a SaaS covers retries and dunning.

Step 4: grant access from subscription status​

While a subscription is in a free trial its status is trialing. Treat trialing and active as access granted in your app, and make the webhook handler the source of truth, not the redirect page. If you have not set up webhook testing, how to test Stripe webhooks locally walks through it.

Step 5: test it with test clocks​

Waiting two weeks to see whether the trial converts is not a test plan. Stripe's test clocks let you advance simulated time in a sandbox. The docs say you can move the clock by any increment, up to two subscription intervals at a time from the initial frozen time, and that the Dashboard may disable the simulation for customers with more than three subscriptions or more than 25 related objects.

A minimal test run:

  1. Create a customer attached to a test clock and start a trial subscription.
  2. Advance the clock to just before the trial ends and confirm your trial_will_end handler ran.
  3. Advance past the end and confirm the first invoice, the status change and your access logic.
  4. Repeat once with a failing test card to watch the failed-payment path.
  5. Repeat once with no card and missing_payment_method set, to check the cancel or pause path.

A newer option: Trial Offers​

Stripe now has a separate Trial Offer API for paid or discounted introductory periods, such as $1 for the first week, and for trials on single subscription items. It is documented under configure trial offers. It has requirements: your integration must use API version 2026-09-30.endive or later, and subscriptions must use flexible billing mode. Trial Offers are not supported in Payment Links or pricing tables, and Checkout support is limited to invited accounts. You also cannot combine them with the legacy trial_end parameter. For a plain free trial on a single plan, trial_period_days is still the simpler route.

Two interactions to know about​

A trial counts as prior history for promotion codes. Stripe's first-time-customer restriction blocks anyone who ever subscribed to a trial, even if they canceled. If you also run a launch code, see how to create a launch discount code in Stripe before deciding which customers get which offer.

Billing analytics also treats trial items differently. In Stripe's analytics, trial offer items do not contribute to MRR while in the trial period, so a growing trial count will not show up as revenue.

Frequently asked questions​

How long can a Stripe free trial be?​

Up to 2 years (730 days) in Checkout. Most businesses use shorter trials such as 30 days, since long trials risk expired cards and lower conversion.

Can I offer a free trial without collecting a credit card in Stripe?​

Yes. Set payment_method_collection to if_required on the Checkout Session, and choose whether the subscription cancels or pauses if no payment method is added before the trial ends.

How do I remind customers before the trial ends?​

Listen for customer.subscription.trial_will_end, which by default fires 3 days before the end, and send your own email. Stripe-hosted reminders are sent 7 days before the end.

How do I test a trial without waiting?​

Use a test clock in a sandbox and advance time. You can move forward up to two subscription intervals at a time.