How SaaS Billing Actually Works
SaaS billing is not simply charging a card monthly. Every subscription state, all six Stripe webhooks that must be implemented, common billing models, and the most expensive billing mistake SA finds in 90% of audited SaaS products.
The Revenue Engine Behind Every Software-as-a-Service Business
SaaS billing is not simply charging a credit card every month. It is a system of subscription management, dunning, proration, upgrades, downgrades, cancellations, trial conversions, and failed payment recovery that must function correctly for a SaaS business to be operationally viable. Most SaaS products built on Bubble.io have billing problems that cost the founder money every week — not dramatically, but continuously. This guide explains how SaaS billing works correctly and what the most common mistakes cost.
Every State a Subscription Passes Through
| State | What It Means | What Your App Must Do |
|---|---|---|
| Trialing | Customer signed up, trial period active (typically 7-30 days) | Show trial countdown; send day-3 and day-1 warning emails; gate paid features |
| Active | Payment taken, subscription running, customer has full access | Grant full plan access; enforce plan limits; update billing period end date |
| Past Due | Payment failed, Stripe retrying automatically | Show urgent payment banner; send failed payment email; allow access during grace period |
| Cancelled | Customer cancelled or payment retry exhausted | Preserve all data; switch to read-only or limited mode; show reactivation prompt |
| Paused | Subscription paused (if you offer this) | Suspend billing; maintain data access at reduced tier or read-only |
| Upgraded | Customer moved to higher plan mid-cycle | Prorate the difference; update plan limits immediately |
| Downgraded | Customer moved to lower plan | Apply at next billing cycle; update plan limits at cycle end |
The Source of Billing Truth
In a correctly implemented SaaS billing system, every state transition described above is triggered by a Stripe webhook event — not by a redirect URL, not by a manual workflow, not by a user action. The webhook is the authoritative source. SA implements all six on every Bubble.io SaaS it builds.
| Webhook Event | Triggers | What the App Does |
|---|---|---|
| checkout.session.completed | Customer completes checkout | Activates account; sets status=Active; stores stripe_sub_id |
| customer.subscription.updated | Plan change, pause, or modification | Updates plan and status from event data |
| customer.subscription.deleted | Cancellation | Sets status=Cancelled; preserves data; shows reactivation prompt |
| invoice.payment_failed | Payment attempt fails | Sets status=Past_Due; shows urgent payment banner; sends email |
| invoice.payment_succeeded | Payment succeeds | Sets status=Active; updates current_period_end |
| customer.subscription.trial_will_end | 3 days before trial expires | Sends conversion email; shows upgrade prompt in app |
Free SaaS Tech Audit — 30 Minutes
Athar Ahmad personally reviews your SaaS product and tells you exactly what is wrong, what is at risk, and what to fix first. Free. No obligation. Written summary within 24 hours.
- SaaS security and privacy rule assessment
- Stripe billing architecture review
- Performance bottleneck identification
- Prioritised remediation roadmap
Which Billing Structure Fits Your Product
Per-seat pricing
Charge per user per month. Scales with team size. Simple to understand. Best for: collaboration tools, team productivity software. Risk: customers minimise seat count.
Usage-based pricing
Charge per unit consumed: API calls, records created, emails sent. Scales with usage. Best for: API products, data tools, communication platforms. Risk: unpredictable revenue.
Flat-rate tiers
Fixed price per tier (Starter/Growth/Scale). Simple. Predictable. Best for: most SaaS products starting out. Encourages upgrade as limits are hit.
Feature-gated tiers
Access to specific features unlocks at higher tiers. Best for: products with clear feature progression. Drives upgrades by demonstrating premium feature value during trial.
Freemium
Free forever tier with limits; paid tier for power users. Best for: products with viral distribution. Risk: conversion rate from free to paid is often below 2%.
Annual vs monthly
Annual plans at 15-20% discount reduce churn, improve cash flow, and lock in customers for longer. SA implements both billing intervals on every SaaS with automatic proration on mid-cycle switches.
Q: What is the difference between SaaS billing and e-commerce billing?
E-commerce charges a one-time payment for a product. SaaS billing charges recurring subscriptions with automatic renewal, usage tracking, plan upgrades, and cancellation management. The technical complexity is significantly higher for SaaS billing.
Q: How do I handle failed payments in a SaaS product?
Stripe automatically retries failed payments (typically 3 attempts over 7-14 days). Your app should: show a payment update banner, send a failed payment email, and maintain a grace period of access during retries. On final failure: set status to Cancelled and show a reactivation prompt.
Q: What is dunning in SaaS billing?
Dunning is the process of communicating with customers whose payments have failed to recover the payment before cancellation. Effective dunning includes automated emails at specific intervals after payment failure, an in-app banner, and a direct payment update link. Well-implemented dunning recovers 20-40% of failed payments.
Ready to Build or Fix Your SaaS?
Two paths: a Free Tech Audit for SaaS products that need assessment, or a Discovery Sprint to scope your new SaaS correctly before a single line is built.