Founder & Lead Engineer, RAITHub
RAITHub ships and tests production software. See QA as a Service or talk to us.
A free trial needs a clock and a freemium plan needs limits. A trial means trial state on each account, reminder emails, and a clean change of access when the clock runs out, driven by billing webhooks. Freemium means a permanent free plan whose limits are enforced on the server, plus infrastructure costs for free users you can afford to carry.
If you would rather have it built for you, see how RAITHub would build this below.
The choice between them is a commercial decision, but each one has a different engineering shape, and changing later means migrating live accounts. This guide covers what each model needs in code, how Stripe handles trials, the 2026 conversion benchmarks, and a way to choose. Pricing models in general are in SaaS billing models explained.
What is the difference between a free trial and freemium?
A free trial gives full or near-full access for a limited time, then asks for payment. Freemium gives limited access forever, and asks for payment when a user needs more.
| Free trial | Freemium | |
|---|---|---|
| What ends access | Time: the trial expires | Limits: a quota or feature gate is reached |
| Core engineering | Trial state, reminders, expiry handling, card collection | Plan limits on the server, usage counting, upgrade prompts |
| Cost of non-payers | Bounded by trial length | Ongoing, for as long as free users stay |
| Main failure | Access not removed, or removed while a payment is still retrying | Limits enforced only in the user interface, so the API ignores them |
| Fits best | Products whose value shows within days, sold to businesses | Products that spread by use and sharing, with low cost per free user |
Which converts better, a free trial or freemium?
Trials convert a higher share of sign-ups; freemium usually brings in more sign-ups. A January 2026 study of 200 self-serve software products by Kyle Poyar with ChartMogul and ProductLed put the median free-to-paid conversion at 8%, found that trials requiring a credit card converted at about 30%, more than 5 times those that did not, and that 14 days was the most common trial length, used by 62% of products (Growth Unhinged, the 2026 free-to-paid conversion report). The same study found 57% of products used a free trial as the main entry point, against 26% for freemium.
A higher conversion rate from fewer sign-ups is not automatically better. Compare paying customers per month, not percentages, and run the comparison for long enough to see churn.
What does a free trial need in code?
Five things, most of which your payment provider can do for you if you configure it.
- A trial state on the subscription. With Stripe, a subscription created with
trial_period_daysortrial_endstarts in thetrialingstatus, and the trial period must be 730 days or less (Stripe Docs: free trial periods). - A decision about the card. Stripe Checkout can start a trial without a card when
payment_method_collectionis set toif_required. - An end behaviour. If no payment method exists when the trial ends,
trial_settings.end_behavior.missing_payment_methodcan becancel,pauseorcreate_invoice(the default, which moves the subscription topast_dueif the invoice cannot be paid). - A reminder. Stripe sends
customer.subscription.trial_will_endbefore the trial ends, by default 3 days before, and its own hosted reminder emails 7 days before (Stripe Docs: trial offers). Use the event to send your own email with a link to add a card. - One trial per customer. Record that an organisation has used its trial in your own database, so cancelling and signing up again does not restart the clock.
Stripe's newer Trial Offer API, which needs API version 2026-09-30.endive or later, also supports paid and per-item trials, but Stripe notes that Checkout and Payment Links do not support trial offers yet; with Checkout you still use the legacy trial period. Check which one your integration uses before building on either.
How should access change when a trial ends?
From webhook events, in one function that maps billing status to access, and nowhere else. Scattered checks such as "if trial_ends_at is in the past" in several places are how users keep paid features after a trial or lose them while a payment is still retrying.
type BillingStatus = 'trialing' | 'active' | 'past_due' | 'paused' | 'canceled' | 'incomplete' | 'unpaid'
type Access = 'paid' | 'grace' | 'free'
// Called with the status saved by your Stripe webhook handler, never with client input.
export function accessFor(status: BillingStatus | null): Access {
switch (status) {
case 'trialing':
case 'active':
return 'paid'
case 'past_due':
return 'grace' // payment is retrying: keep access, show a banner
default:
return 'free' // paused, canceled, unpaid, incomplete or no subscription
}
}
Every server route and background job then asks for the account's access level, not for the raw status. If you offer freemium as well, free means the free plan's limits; if you do not, it means a read-only or locked account. The pattern for enforcing those limits consistently is in SaaS entitlements and plan limits, and the webhook side in Stripe webhook returns 200 but the subscription is not updated.
What does freemium need in code?
Limits enforced where the data is written, usage counted reliably, and a cost model you have checked.
- Server-side limits. If the free plan allows three projects, the API that creates a project checks the count inside the same transaction. A limit that only hides a button is not a limit.
- Usage counting. For quotas such as messages or exports, count in your own database with a monthly reset, and make the counter safe against double requests.
- Upgrade prompts at the limit. Return a clear error code when a limit is hit, so the interface can show what upgrading unlocks rather than a generic failure.
- Clean-up of inactive free accounts. Decide in writing how long data from inactive free accounts is kept, and say so in your terms.
- A cost ceiling. Free users consume storage, email and, for AI features, model calls. Work out the monthly cost per free user before launch; the line items are in what a SaaS costs to run per month.
Do-it-yourself estimate: a developer who already has Stripe subscriptions working can add a no-card trial with reminders and a single access function in 2–4 days, and server-enforced freemium limits for two or three quotas in another 3–5 days. The main risk is a free tier whose cost grows faster than paid conversions.
Can you combine a trial and freemium?
Yes, and many products do: a permanent free plan, plus a time-limited trial of the paid plan that falls back to free instead of locking the account. In code that is the access function above with free mapped to the free plan, and one rule: a trial of paid features never deletes data created during it. When the account falls back, data over the free limit becomes read-only rather than disappearing.
Feature flags help here, because you can test different trial lengths or free limits on a share of new sign-ups without a deploy; see feature flags for SaaS.
How do you choose between a free trial and freemium?
| If your product… | Lean towards |
|---|---|
| Shows its value in the first session or two | A free trial, often 14 days |
| Needs setup, data import or a team before it is useful | A longer trial, or a guided trial with onboarding help |
| Spreads when users share or invite others | Freemium |
| Costs real money per active user, such as AI or heavy storage | A free trial, or freemium with tight quotas |
| Sells to businesses with procurement | A trial, plus a sales-assisted pilot for larger accounts |
Buy, build or hire?
| Option | Choose this when | Watch out for |
|---|---|---|
| Off-the-shelf billing features | Stripe's trial settings, hosted checkout and customer portal cover your model | You still own access control, limits and the one-trial-per-customer rule |
| Template or SaaS boilerplate | You want auth and billing pre-wired and your pricing is simple | Boilerplates often check trial dates in the client and skip server-side limits |
| Custom build | You combine trials, freemium, add-ons or usage, or sell to businesses with seats | Needs tests for every status change, including retries and pauses |
Why RAITHub for this
- Subscription billing in production. PropDesk, a property-management SaaS, collects rent through Stripe and runs 1,024 automated tests.
- Rules enforced on the server. Sundor Skin enforces 88 permission codes across 12 staff roles with row-level security on 146 PostgreSQL tables, and 530+ tests.
- Webhook experience. This website itself runs 400+ tests, and payment and webhook testing is covered in testing payments and webhooks.
When you don't need us
- Your Stripe setup already works and you only need a trial: the Stripe settings above and a day of work may be enough.
- You have not decided on pricing. Decide the model and limits first; code follows.
- You sell only through sales-led pilots. A manual pilot agreement may serve better than any self-serve trial.
How RAITHub would build this
Scope, agreed in a written spec before production code:
- Trial or freemium configuration in Stripe, including card rules and end behaviour.
- A verified, idempotent webhook handler and one access function used by every route and job.
- Server-side plan limits with clear upgrade errors, and a one-trial-per-organisation rule.
- Reminder emails, an upgrade flow and fallback to free or read-only without data loss.
- Tests for every billing status change, including retries, pauses and cancellations.
Timeline: 4–6 weeks at fixed scope when built as part of a SaaS MVP; a smaller, fixed scope when added to an existing product.
You receive: automated tests and CI, handover docs and runbooks, and full IP under NDA.
Next step: a free 15-minute technical audit, then a written fixed quote. See the SaaS development service, or book the audit.
Frequently asked questions
What is the difference between a free trial and freemium?
A free trial gives full access for a limited time, then asks for payment. Freemium gives limited access with no time limit and asks for payment when a user needs more.
Does a free trial or freemium convert better?
Trials usually convert a higher share of sign-ups. A 2026 study of 200 self-serve products found a median free-to-paid conversion of 8%, and about 30% for trials that required a credit card.
How long should a SaaS free trial be?
Long enough for a typical user to reach the product's main value. In the 2026 study, 14 days was the most common length, used by 62% of products. Stripe allows trials of up to 730 days.
Should a free trial require a credit card?
Requiring a card raises conversion but lowers sign-ups. Stripe supports both: Checkout can start a trial without a card, and the subscription can cancel, pause or invoice when the trial ends with no card.
How do I stop users keeping paid features after a trial ends?
Update each account's status only from verified billing webhooks, and decide access in one server-side function that every route uses. Never trust a trial date sent from the browser.
Can I offer both a free plan and a free trial?
Yes. A common pattern is a permanent free plan plus a trial of the paid plan that falls back to free when it ends, keeping data over the free limit read-only rather than deleting it.
Is a free trial or freemium plan a risk to our infrastructure or revenue?
Both invite abuse, so build limits in: cap resource use on free accounts, rate-limit signups, and make downgrades degrade gracefully rather than deleting data. The engineering risk is uncontrolled cost from non-paying users; the revenue risk is giving away the feature that would have converted them. Gate the high-cost and high-value features deliberately.
We cannot decide between a free trial and freemium for our SaaS — how should we choose and what changes in the code?
Choose by how fast a user reaches value: a trial suits products that prove worth quickly; freemium suits products with a low-cost tier that drives word of mouth. In code, a trial needs an expiry and a graceful fallback; freemium needs permanent per-plan limits and entitlement checks. You can run both, with a trial of the paid plan that falls back to free.
Who should I hire to build the trial or freemium mechanics for my SaaS?
A team that builds the clock for a trial, state, reminders and a clean change of access at the end, or the server-enforced limits for freemium, with costs you can carry. RAITHub builds either on your billing stack. Ask any vendor how they stop a user keeping paid features after a trial ends or after a downgrade.
Is using Stripe's built-in trials an alternative to building trial logic myself?
Stripe handles the trial clock and the transition to a paid subscription, which saves real work. You still enforce what the user can access during and after the trial in your own entitlements, and build reminders. Use Stripe for the billing-side clock; build the access changes and the in-app nudges yourself, driven by Stripe's webhooks.
What's involved in building a trial or freemium model, and how long does it take?
For a trial: trial state, reminder emails and a clean change of access when it ends. For freemium: a permanent free plan enforced on the server with limits you can afford. Either is usually a one to two week engagement. Freemium adds ongoing cost control, because you carry the free users' infrastructure indefinitely.
Can I just flip a flag when the trial ends and leave the rest?
A single flag is not enough. You need to decide what happens to the user's data and access the moment the trial ends, send reminders before it does, and make sure paid features are gated on the server so a stale client cannot keep using them. Model the trial as a state with a clear, enforced transition, not one boolean.
Related posts
Ready to discuss your project?
Book a free 15-minute technical audit with our engineering team.