Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Cashier Laravel Package

laravel/cashier

Laravel Cashier offers a fluent Laravel interface for Stripe subscription billing. Manage subscriptions, coupons, plan swaps, quantities, and cancellation grace periods, with support for generating invoice PDFs—all while handling the boilerplate billing code.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Subscription Monetization Model: Enables rapid implementation of recurring revenue models (e.g., SaaS, memberships, digital products) with minimal backend complexity.
  • Roadmap Prioritization:
    • Phase 1: Launch core subscription tiers (e.g., Free, Pro, Enterprise) with tiered pricing and features.
    • Phase 2: Add usage-based billing (e.g., pay-as-you-go APIs, metered services) via Stripe’s usage-based pricing.
    • Phase 3: Integrate Stripe Basil for fraud detection or Stripe Tax for compliance.
  • Build vs. Buy: Buy—avoids reinventing billing logic, reduces Stripe API integration risk, and leverages Laravel’s ecosystem (e.g., Eloquent models, migrations, webhooks).
  • Use Cases:
    • B2B/B2C SaaS: Tiered subscriptions with trials, coupons, and prorations.
    • Marketplaces: Seller subscriptions with variable quantities (e.g., "10 API calls/month").
    • Content Platforms: Paywalls, ad-free tiers, or early access.
    • Global Scalability: Localized pricing, taxes, and multi-currency support via Stripe.

When to Consider This Package

Adopt if:

  • Your stack is Laravel-based (PHP 8.1+ recommended; v16.x supports Laravel 10–13).
  • You need Stripe subscriptions but lack in-house billing expertise.
  • Requirements include:
    • Subscription management (create, pause, cancel, swap plans).
    • Coupons/promotions (e.g., "20% off annual plans").
    • Invoice generation (PDFs for compliance/tax purposes).
    • Webhook handling (e.g., customer.subscription.updated for real-time updates).
    • Usage-based billing (e.g., metered pricing for APIs).
  • You prioritize developer velocity over custom billing logic.

Look elsewhere if:

  • You’re not using Laravel (e.g., Node.js, Python, or a headless setup).
  • You need multi-vendor payments (consider Laravel Cashier + Stripe Connect).
  • Your billing model is highly bespoke (e.g., complex volume discounts, non-Stripe gateways).
  • You require offline payments (Cashier is Stripe-centric).
  • Your team lacks PHP/Laravel familiarity (steep learning curve for customizations).

How to Pitch It (Stakeholders)

For Executives: "Laravel Cashier + Stripe lets us launch subscriptions in weeks, not months. It handles the heavy lifting—recurring billing, dunning (failed payments), coupons, and even invoice PDFs—so our team can focus on product growth. Stripe’s global infrastructure ensures compliance (taxes, PCI) and fraud protection, while the Laravel integration keeps our stack consistent. Early adopters like [Example SaaS] reduced billing-related dev time by 70% and scaled to 10K+ subscribers without hiring dedicated billing engineers."

For Engineering: *"Cashier abstracts Stripe’s subscription API into Laravel-friendly methods (e.g., $user->newSubscription('pro')->create($plan)). Key benefits:

  • Webhooks: Built-in HandleWebhook controller for events like invoice.paid or customer.subscription.deleted.
  • Migrations: Pre-built database schema for users, subscriptions, and invoices.
  • Testing: Mock Stripe responses with Laravel’s testing tools.
  • Extensibility: Override default behavior (e.g., custom trial logic) via service providers. Tradeoff: Tight coupling to Stripe, but the package is battle-tested (used by Laravel’s core team)."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport