Smart Billing

Automate recurring revenue with Billing.

Manage subscriptions, invoice customers, and accept recurring payments globally. Built to support any pricing model, from flat-rate and tiered to usage-based billing.

Subscription Active

Pro Plan (Annual)

Next invoice $1,200.00
Billing cycle Apr 22, 2027
Automated tax collection
Smart retries enabled

Built for B2B and B2C

Whether you're selling software seats, usage-based APIs, or physical subscription boxes, NextGen Billing handles the complex edge cases.

Flexible Pricing

Support for flat-rate, per-seat, tiered, and metered usage models out of the box. Change pricing tiers instantly without breaking existing subscriptions.

Automated Invoicing

Generate beautiful, branded PDF invoices automatically. We handle proration, localized tax rates, and credit note management effortlessly.

Revenue Recovery

Recover lost revenue with Smart Retries. Our machine learning models predict the best time to retry failed cards, recovering up to 14% more revenue.

Start a subscription in a single API call.

Attach a customer to a pricing plan and let NextGen handle the rest. Webhooks will keep your database in sync whenever a billing cycle renews or a payment fails.

View API Documentation
subscription.js
const nextgen = require('nextgen')('sk_test_123');

// Subscribe the customer to the Pro Plan
const subscription = await nextgen.subscriptions.create({
  customer: 'cus_4K9m1Z',
  items: [
    { price: 'price_pro_annual' },
  ],
  expand: ['latest_invoice.payment_intent'],
});

console.log(subscription.status); // 'active'