Build log/SaaS

Billing for a new SaaS: plans, trials and the edge cases

Taking a card payment is easy. Running subscriptions is not: upgrades, failed payments, tax and cancellations all need deciding before launch.

The short answer

  • Use a billing platform such as Stripe Billing rather than building subscription logic yourself.
  • Decide upgrades, downgrades, trials and failed-payment handling before launch, not after the first support ticket.
  • Keep your app’s record of each customer’s plan in sync with the billing platform through webhooks.

Don’t build billing from scratch

Subscriptions involve proration, retries, invoices, receipts, tax and card updates. Platforms such as Stripe Billing handle these, along with a hosted customer portal where customers update cards and download invoices. Your product should own the plan logic and leave the money movement to the platform.

Decisions to make before launch

  • Plans and limits. What each plan includes, and what happens when a customer reaches a limit.
  • Trials. Whether a card is needed to start, and what happens when the trial ends.
  • Upgrades and downgrades. Whether changes take effect now with a prorated charge, or at the next renewal.
  • Failed payments. How many retries, which emails go out, and when access is restricted.
  • Cancellations. Whether access continues to the end of the paid period, and what happens to the data.
  • Tax. VAT for UK customers, and the rules for selling abroad.

Keep the app and the billing platform in sync

The billing platform is the source of truth for payments. Your app needs to know the result: which plan a workspace is on and whether it is paid up. That is done with webhooks, messages the platform sends when something changes, handled so that a repeated or late message never puts an account in the wrong state.

Test the unhappy paths

Test cards that decline, cards that expire mid-subscription, refunds, disputes, and a customer who upgrades and cancels on the same day. Billing bugs are expensive and very visible, so they get their own tests.

This isn’t tax advice. HMRC’s guidance is the authority on how VAT applies to what you sell.
Written by Flavoureak

We build and run Estimark, CurioKids and CalcStack, and we build web and mobile software for other businesses. Start a project.