Skip to content
Laravel Integration

Laravel + Stripe Integration

Accept payments, handle subscriptions, and manage payouts in your Laravel application with Stripe.

What You Can Build

One-Time Payments

Accept credit card payments for products, services, or donations with Stripe Checkout.

Subscription Billing

Recurring payments with trials, tiers, usage-based billing, and automatic renewals.

Marketplace Payments

Split payments between sellers and platform with Stripe Connect.

Webhooks & Automation

Real-time notifications for successful payments, failed charges, and subscription events.

How It Works

1

Install Stripe Package

Laravel Cashier provides a clean API on top of Stripe.

2

Configure API Keys

Add Stripe keys to your .env file and configure webhooks.

3

Create Models

Add Billable trait to your User model for subscription support.

4

Build Checkout Flow

Use Checkout Sessions or embed payment forms in your app.

Example Code

// Create a subscription
$user->newSubscription('pro', 'price_monthly')->create($paymentMethod);

// Check subscription status
if ($user->subscription('pro')->active()) {
    // Grant access to premium features
}

// Cancel subscription
$user->subscription('pro')->cancel();