How to Build a Subscription Billing System: Plans & Invoicing
A subscription billing system is not just a Stripe integration. It is a revenue engine with plans, proration, taxes, dunning, invoicing, and ASC 606 revenue recognition built in. Get the architecture right at MVP, and you ship pricing changes in a day. Get it wrong, and every plan tweak takes a sprint. This guide is the operator's map.
Sanjay Prajapati
As Head of Business at Acquaint Softtech, an Official Laravel Partner with 1,300+ projects delivered, I review SaaS billing builds every month. The single most common mistake is treating a subscription billing system as a Stripe checkout button. It is not. It is the revenue layer of your product. Plans, proration, dunning, tax, invoicing, and revenue recognition all sit inside it.
The Complete Guide to SaaS Product Development in 2026 explains this in detail as a full architectural layer of modern SaaS systems. This guide gives you the architecture blueprint, the 6 modules every system needs, the cost at three scope tiers, and the build vs buy decision in 2026.
- SaaS founders and CTOs planning scalable pricing and billing systems.
- Revenue and finance teams need accurate MRR, revenue, and churn tracking.
- Engineering leads deciding what billing components to build or buy.
Problem
Your SaaS has Stripe Checkout glued to a webhook listener and a 'subscriptions' table. Every pricing change takes a sprint. Mid-cycle upgrades produce wrong invoice totals. Failed payments silently churn customers because no one built dunning. Finance asks for an ASC 606 deferred revenue report, and you have nothing. The product owns billing logic only until the first enterprise customer asks for net-30 terms in a PO.
Agitate
Stripe handles payments. It does not handle pricing logic, proration math, dunning sequences, tax compliance, invoice templates, or revenue recognition. Founders learn this at the worst moment: when annual contracts start arriving, when SOC 2 lands, or when a failed-card cohort silently churns 3 percent of MRR. Acquaint Softtech has rebuilt 14 billing systems in the last 24 months. Average rework cost: $35,000 to $90,000. Average time lost: a full product quarter.
Solution
Treat billing as a first-class subsystem with 6 named modules: catalog, subscription state, proration, dunning, invoicing, and revenue recognition. Pick the right buy-versus-build line for each module. This guide gives you the architecture, the math, the cost, and the build sequence. Every figure is from Acquaint Softtech's delivery data from 2022 to 2026.
Why a Subscription Billing System Is Its Own Subsystem
A subscription billing system converts your pricing intent into recurring revenue. It is not a payment gateway. Stripe and Paddle process payments. Your billing system decides who pays, what they pay, when they pay, what happens when payment fails, what tax to add, what invoice to send, and how to book the revenue. Treating Stripe as your billing system is the same mistake as treating S3 as your CMS.
The FASB's Topic 606 requires subscription revenue to be recognised as service is delivered, not when cash is received. A customer who pays $12,000 for an annual plan generates $1,000/month in recognised revenue, not $12,000 on day one. Your billing system has to know this. Stripe does not.
The 6-Module Billing Architecture Blueprint
Every production-grade billing system has 6 distinct modules. Build each as a separable concern. The table names each module, its single responsibility, and the failure mode you get when it is missing or coupled to the wrong layer. Patterns from Acquaint Softtech software product development and delivery across SaaS clients from 2022 to 2026.
Module | Single Responsibility | Tech / Library Pattern | Failure if Missing |
Plan Catalog | Products, plans, prices, features, plan-level entitlements. The single source of truth for what can be sold. | Stripe Products + Prices OR custom catalog table with versioning | Pricing changes require code deploys |
Subscription State | Per-customer lifecycle: trialing → active → past due → canceled → reactivated, with audit trail. | Custom state machine + Stripe Subscription mirror | Lost upgrade history; broken refund logic |
Proration Engine | Mid-cycle changes: credit unused time, charge prorated new plan, handle add-ons. | Stripe proration setting OR custom day-count algorithm | Wrong invoice totals on every upgrade |
Invoicing | Generate, brand, deliver, and store invoices. PDF + accessible HTML, with tax and currency. | Stripe Invoices OR custom (Snappy/Browsershot) | Enterprise buyers refuse to pay; PDFs look unprofessional |
Dunning Engine | Failed-payment retries, customer comms, grace period, smart retry timing. | Stripe Smart Retries + custom email cadence | 3 to 8 percent of MRR churns silently per quarter |
Revenue Recognition | Defer cash; recognise revenue as service is delivered; produce ASC 606 reports. | Custom rev-rec table + monthly journal entries | Finance cannot close the books; audit fails |
Architecture pattern based on Acquaint Softtech production SaaS delivery 2022–2026. Stripe modules can be substituted with Paddle or Chargebee equivalents.
The decision principle: every module should be replaceable without rewriting the others. If your dunning logic is glued to your invoice generator, you cannot switch dunning providers without breaking PDF generation. Loose coupling at module boundaries is what makes billing systems survive provider switches. Our hired Laravel developer team builds this with Laravel Cashier as the payment adapter and the 6 modules as separate services.
Want a Billing Architecture Review for Your SaaS?
Send us your current pricing page, your tenant count, and your average revenue per tenant. Acquaint Softtech architects with a written billing module map with build-versus-buy recommendations within 48 hours. You interview the team before any engagement begins.
Plan Modelling: From Flat-Rate to Seat-Based to Usage-Based
The plan catalog is where pricing strategy meets engineering. The wrong data model forces every pricing experiment to become a database migration. Three archetypes cover roughly 90 percent of SaaS pricing in 2026. The cards below map each one to the data structure that supports it cleanly. For pricing strategy context, see the Monetization Strategies for SaaS Products guide.
Flat-Rate Same price, same features | Seat-Based Price × seats | Usage-Based Price × metered events |
Best when: Pre-PMF startups; product-led freemium tiers; ARPU under $50/mo Data model: plans table with id, name, monthly price, annual price Avoid when: Enterprise sales motion; products where value scales with usage | Best when: B2B SaaS where teams are the unit; collaboration, project tools, CRM
subscriptions table with plan ID and seat count; usage records for adds/removes Avoid when: Single-user consumer products; usage-driven workloads | Best when: Developer tools, AI APIs, telephony, storage, analytics platforms Data model: metered events table, append-only; nightly rollup to invoice Avoid when: Predictability-sensitive enterprise buyers without a cap |
The data-model rule most teams break
Never store the current price on the subscription. Store a reference to a price object, and version the price object. When you change Plan A's price from $29 to $39, existing subscribers continue at $29 until their renewal date. New subscribers see $39.
Mutating the original row makes every existing customer's next invoice wrong. Stripe handles this with immutable Price objects. Custom systems must replicate the pattern. The Best Laravel Packages guide covers Laravel Cashier, which mirrors Stripe's Price model, so you don't write this versioning yourself.
The Proration Math: Mid-Cycle Upgrades, Downgrades, and Refunds
Proration is the math that decides what happens when a customer changes plans mid-cycle. Get it wrong, and every customer-success ticket about a confusing invoice traces back to the same five lines of code. Get it right, and customers upgrade without thinking, because the invoice tells a clean story.
The four proration events
Upgrade mid-cycle: Customer on Plan A ($29/mo, 10 days into cycle) upgrades to Plan B ($79/mo). Credit unused 20 days of A: $19.33. Charge prorated 20 days of B: $52.66. Net immediate charge: $33.33. Next full invoice on the regular renewal date for $79.
Downgrade mid-cycle: Two patterns. End-of-cycle (the SaaS standard): customer keeps Plan B until renewal, then switches. Immediate with prorated credit toward next invoice. End-of-cycle avoids refund processing and confusion.
Add-on mid-cycle: Customer adds 5 seats on day 10 of a 30-day cycle. Charge 20/30 of the per-seat price × 5. Next renewal charges full per-seat price × total seats.
Refund/cancellation: Service through end of paid period (SaaS standard, no refund, no further charges), or pro-rata refund of unused days. Refund processing must be a separate, audited workflow.
The proration formula
Credit for unused time on old plan: old price × (days remaining / cycle days)
Charge for prorated new plan: new price × (days remaining / cycle days)
Net immediate charge: charge new, credit old (clamped to ≥ 0)
Day-count basis: Use one basis everywhere, calendar days in the customer's timezone. Document it in the ADR; never mix bases.
Stripe's proration setting handles this automatically for plan changes through the API. For custom logic, implement as a pure function with a clear test suite. Edge cases that bite: leap years, daylight-saving boundaries, annual cycles with Feb 29, and downgrades from add-ons that no longer exist on the new plan.
Invoicing, Dunning, and the Revenue Recovery Loop
Together, invoicing and dunning decide how much billed revenue actually arrives in your bank account. Without a dunning system, involuntary churn, customers whose card failed, and no one recovered them, typically runs at 5 to 8 percent of MRR for SaaS. With a mature one, under 1 percent. Our dedicated developers in the India team can ship the full 4-stage cadence in 3 to 4 weeks.
The 4-stage dunning cadence
Stage | Trigger | Customer Comms | Engineering Behaviour |
Stage 1 | Day 0: charge fails | Friendly notification email; in-app banner | Retry in 3 days; subscription stays active |
Stage 2 | Day 3: 2nd fail | 2nd email; surface in customer portal | Retry in 5 days; mark past due |
Stage 3 | Day 8: 3rd fail | Final-notice email with deadline | Retry in 7 days; restrict premium features |
Stage 4 | Day 15: final fail | Cancellation email with 1-click reactivation link | Cancel subscription; preserve data 90 days |
Cadence calibrated from Acquaint Softtech production data across 11 SaaS billing builds. Stripe Smart Retries handles stages 1–3 automatically with ML-based timing; Stage 4 cancellation logic must be implemented by the application.
Invoicing essentials your customers actually read
Customer's legal entity, billing address, and tax ID (essential for B2B and EU/UK buyers).
Line items by performance obligation, not Stripe charge ID; finance reconciles by service.
Tax broken out by jurisdiction (sales tax, VAT, GST) with the rate displayed.
Sequential, stable, human-readable invoice number; auditors check this.
PDF + HTML formats; PDF for accounting systems, HTML for accessibility.
For PCI compliance, never store raw card numbers in your application. Tokenise through Stripe or Paddle and reference the token. The PCI Security Standards Council guidance treats card data as the highest-sensitivity payload your system can touch. Our Virtual CTO engagements include a billing PCI scope review as a Phase 1 deliverable.
For Python-stack billing, our hiring Python developers practice has a tested Django Stripe integration template. For Laravel-side patterns, the payment gateways in Laravel guide cover Stripe, PayPal, and Authorize.Net.
Build vs Buy in 2026: Stripe Billing, Paddle, Chargebee, or Custom
Build versus buy is six decisions, one per module. The table below maps each module to the realistic options and the conditions under which each option wins. Built on Acquaint Softtech software development outsourcing experience across SaaS clients shipping in 2025 and 2026.
Module | Buy (default) | Build (only if) | Hybrid | Cost-Order |
Plan Catalog | Stripe Products & Prices | Pricing rules cannot be expressed in Stripe | Stripe + override table | Low |
Subscription State | Stripe Subscriptions | Custom states beyond active, past due, canceled | Mirror table in your DB | Low |
Proration Engine | Stripe proration | Non-standard cycle (academic year, fiscal year) | Custom for edge cases only | Medium |
Invoicing | Stripe Invoices | Branded PDF; enterprise PO terms; multi-entity billing | Stripe data + custom PDF render | Medium |
Dunning | Stripe Smart Retries (built-in) | Need branded comms; non-email channels (SMS, in-app) | Smart Retries + your email engine | Low |
Revenue Recognition | Chargebee RevRec or Maxio | Tight budget; simple SaaS; under $5M ARR | Custom rev-rec table | High |
Cost-Order: Low = under $30/mo for Stripe usage at a small scale. Medium = $50–$200/mo. High = $400–$2,000/mo for managed rev-rec or 30–60 engineering days to build custom.
The default in 2026 for SaaS under $10M ARR: Stripe Billing for modules 1 through 5, custom revenue recognition in your application database. Move modules off Stripe only when a specific business requirement cannot be expressed inside Stripe's data model. Premature custom-building is the most common over-engineering mistake in early-stage SaaS. The How to Build a Scalable Laravel App guide applies the same buy-versus-build discipline to caching and queueing.
What It Costs to Build a Subscription Billing System in 2026
Cost figures: composite of Acquaint Softtech engagements 2022 to 2026, USD, offshore delivery from India. Engineering work only; payment processor fees are excluded because they vary by volume and geography.
Build Scope | Engineering Cost | Timeline | What's Included |
MVP Billing | $8,000–$18,000 | 4–6 weeks | Stripe Checkout + Webhook listener + basic subscription table + 1 plan |
Growth Billing | $22,000–$45,000 | 8–12 weeks | All 6 modules; multi-plan; proration; basic dunning; branded invoicing |
Enterprise Billing | $55,000–$110,000 | 16–24 weeks | Multi-currency; tax automation; ASC 606 rev-rec; net-30 PO; SOC 2 controls |
What the engineering rate includes at Acquaint Softtech
Plan catalog design: Stripe Product/Price modelling, versioning, feature flag entitlements
Subscription state machine: Trial → active → past due → canceled with audit trail
Proration engine: Upgrade, downgrade, add-on, refund flows with edge-case tests
Branded invoicing: PDF + HTML, multi-currency, tax line, sequential invoice numbers
Dunning workflow: Smart Retries + branded comms; cancellation handling
Revenue recognition: ASC 606 schedule, deferred revenue table, monthly journal export
Customer billing portal: View invoices, update card, cancel; iOS/Android/web tested
The rate the client pays is the rate. No additional employer overhead on top. For fractional senior billing engineering, our staff augmentation team deploys vetted engineers within 48 hours. For end-to-end ownership, our MVP development company ships the full 6-module system in the timelines above.
For webhook reliability and queue tuning under load, our hired DevOps engineers practice runs the production reliability layer that keeps the billing event stream lossless.
Once the product is shipped, the support and maintenance team takes over key financial and operational workflows. This includes managing the dunning process (handling failed payments, retries, and recovery of overdue subscriptions) and ensuring the monthly revenue recognition (rev-rec) close is completed accurately for accounting and reporting. At the same time, all platform updates, security patches, and dependency upgrades are handled through structured software version upgrade services, so the system stays stable, compliant, and up to date without disrupting live operations.
Want a Scoped Cost Estimate for Your Billing Build?
Tell Acquaint Softtech your current billing setup, your tenant count, your plan structure, and whether you need ASC 606 revenue recognition. We send a scoped estimate with team composition and timeline within 48 hours. You interview before you commit.
Frequently Asked Questions
-
How much does it cost to build a subscription billing system in 2026?
Billing Platform Type
Estimated Cost
MVP with Stripe Checkout
$8,000–$18,000
Production Ready Billing System
$22,000–$45,000
Enterprise Billing Platform
$55,000–$110,000
-
How long does subscription billing development take?
An MVP can usually be built in 4–6 weeks with one senior engineer. A growth-stage billing platform generally takes 8–12 weeks with a small team. Enterprise-level systems may require 16–24 weeks because of added complexity, like tax handling and revenue recognition.
-
What tech stack is best for a subscription billing system?
For Laravel projects, Laravel Cashier works well with Stripe and Paddle integrations. Python projects commonly use Django with dj-stripe or FastAPI with Stripe SDK. PostgreSQL is often used for storing billing data, while Redis helps manage webhook queues.
-
Should I build a billing system from scratch or use Stripe Billing?
For most SaaS businesses under $10M ARR, Stripe Billing is the better choice because it handles most billing needs. Custom development is mainly useful for advanced requirements like unique pricing structures or complex contracts. Building everything from scratch too early often increases cost and development time.
-
What features does a SaaS billing system need?
A billing system should include catalog management, subscription handling, invoicing, proration, dunning, and revenue recognition. It should also provide customer-facing tools like checkout, billing portals, and card updates. Admin features such as refunds, coupons, and reporting are also important.
-
How is proration calculated mid-cycle?
Proration works by giving credit for unused time from the old plan and charging for the remaining time on the new plan. The final charge is the difference between the two amounts. Most payment platforms like Stripe can automate this process.
-
Why hire Acquaint Softtech for subscription billing development?
Acquaint Softtech has delivered billing systems using Stripe, Paddle, Chargebee, and Laravel Cashier across multiple SaaS projects. Their team includes multi-stack engineers who handle both architecture and development. They also provide quick proposals and project planning with a structured development approach.
Table of Contents
Get Started with Acquaint Softtech
- 13+ Years Delivering Software Excellence
- 1300+ Projects Delivered With Precision
- Official Laravel & Laravel News Partner
- Official Statamic Partner
Related Blog
The Complete Guide to SaaS Product Development in 2026
SaaS product development in 2026 is five interlocking decisions: architecture, billing, compliance, AI, and team model, each with a costly alternative if made in the wrong order. This guide covers all five with specific cost ranges, comparison tables, and real delivery data from 1,300+ projects.
Acquaint Softtech
May 7, 2026Multi-Tenant SaaS Architecture Comparison: Shared vs Database-per-Tenant
Multi-tenant SaaS architecture is not three flavours of the same idea. Shared database, schema-per-tenant, and database-per-tenant are three different operational contracts with your future self. This guide tells you which model fits each business condition, what each costs to run at 50, 500, and 5,000 tenants, and the 5-question decision framework Acquaint Softtech architects use before writing the first migration.
Ahmed Ginani
May 15, 2026Introduction to SaaS Development - Basics Principles
Are you curious about SaaS and its potential benefits for your business? Dive into our latest article and learn how SaaS can enhance your efficiency and scalability.
Mukesh Ram
September 10, 2024India (Head Office)
203/204, Shapath-II, Near Silver Leaf Hotel, Opp. Rajpath Club, SG Highway, Ahmedabad-380054, Gujarat
USA
7838 Camino Cielo St, Highland, CA 92346
UK
The Powerhouse, 21 Woodthorpe Road, Ashford, England, TW15 2RP
New Zealand
42 Exler Place, Avondale, Auckland 0600, New Zealand
Canada
141 Skyview Bay NE , Calgary, Alberta, T3N 2K6