Open Source Billing API
for Product-Led SaaS

The best alternative to Chargebee, Recurly and Stripe Billing.
For usage-based, subscription-based, and all the nuances of pricing in between.

Thanks for subscribing to our newsletter!

error message
Oops, a problem occurred while submitting your email. Please try again or don't hesitate to reach out if the issue remains unsolved.
Backed by
Y Combinator

1// Ingest metered events to aggregate billing usage
5curl --location --request POST "$LAGO_URL/api/v1/events"/
6--header "Authorization: Bearer $API_KEY" /
7--header 'Content-Type: application/json' /
8--data-raw '{ 
9	"event": {
10		"transaction_id": "1234_5678_9012_3456",
11		"customer_id": "0987_6543_3210_0987",
12		"code": "api_calls",
13		"timestamp": 1653481578,
14		"properties": { 
15			"nb_api_calls": 12
16		}
17	}

Billing metric

Monitor usage with real-time events

Lago ingests all events coming from your back-end system and converts them into billable metrics that track your customers’ consumption.

Maneki-Lago measures consumption

1// Charge those billing events inside plans, with flexibility!
5curl --location --request POST "$LAGO_URL/api/v1/subscriptions" /
6--header "Authorization: Bearer $API_KEY" /
7--header 'Content-Type: application/json' /
8--data-raw '{ 
9	"subscription": {
10		"customer_id": "0987_6543_3210_0987",
11		"plan_code": "premium"
12	}

Configure price plans

Add usage-based charges to your plans

Our flexible pricing models allow you to create hybrid pricing plans that may include a subscription and multiple consumption-based charges.

Maneki-Lago creates pricing plans

1// Lago automatically aggregates charges into invoices
2"fees": [
3   {
4     "item": {
5	   "type": "subscription",
6	   "code": "premium",
7	   "name": "Premium"
8     },
9     "amount_cents": 1000,
10     "amount_currency": "USD",
11     "vat_amount_cents": 200,
12     "units": "1"
13     },
14     "item": {
15	   "type": "charge",
16	   "code": "api_calls",
17	   "name": "API Calls"
18     },
19     "amount_cents": 1550,
20     "amount_currency": "USD",
21     "units": "12901"
22     }]


Issue auto-generated invoices

Depending on the configuration of your plans, Lago automatically calculates how much you are owed and generates an invoice for each customer.

Maneki-Lago generates invoices

Measure, price, invoice
and keep your favorite tools in sync

Billing system

Bill your customers
seamlessly and effortlessly


Create marketing campaigns with coupons that customers can redeem to get a discount on their next invoice.

Assign couponsAssign couponsAssign couponsAssign couponsAssign coupons


Use add-ons to charge for additional services and products, such as implementation support and optional features.

Assign add-onsAssign add-onsAssign add-onsAssign add-onsAssign add-ons

Real-time usage

Monitor consumption throughout the billing cycle and help customers understand how they are charged.

Billing logsBilling logsBilling logsBilling logsBilling logs

Tax management

Define tax rates at company level or customer level to ensure compliance with local legislation.

Tax rateTax rateTax rateTax rateTax rate

For subscription-based, usage-based
and hybrid pricing models


Handle dozens of recurring and one-off banking fees.
Bypass payment processors by debiting your own wallets.

Example of fintech billing

API solution

Use any end-point as a billable metric.
Offer prepaid credits to get paid in advance.

Example of API billing

Data management

Charge recurring platform fees.
Increase your revenue by billing customers for overage.

Example of data management billing

Could infrastructure

Create a Heroku-like pricing model in no time.
Assign several plans to a customer and measure consumption.

Example of cloud billing

We ship incredibly fast
and it’s only the beginning


Thanks for subscribing to our newsletter!

error message
Oops, a problem occurred while submitting your email. Please try again or don't hesitate to reach out if the issue remains unsolved.

Built for teams
who need more control

Billing composability

Use our event-based infrastructure, or fork it to fit your specific pricing model without begging us for a product update.

Cost controlled billing

Our self-hosted version is free forever. We will not take a percentage of your hard-earned revenue. More information here.

Privacy biling

Your customer and financial data never has to leave your infrastructure. Stay in total control.

Have some questions?

Why is your solution open-source?
Billing API

You can find our detailed answer in this blog post, but essentially:

1/ To address the issue of the increasing diversity and complexity of pricing models
Combinations of pricing dimensions (recurring fees, one-off, payment fees, etc.) are infinite, and teams usually want to iterate on these models over time. That’s why engineers end up investing a huge amount of time to maintain their own billing system, even when they already use an existing closed-source billing service like Stripe Billing or Chargebee.
2/ To offer a way out of the 'rent seeker' pricing model (a cut on transaction volume)
We aim at striking a fairer pricing model for our own service, not relying on taking a cut on each transaction that goes through Lago. To start with, our open-source library is forever free.

Which open-source license did you choose?
Billing API

We chose the AGPLv3 license. We believe that this license will allow us to create a sustainable model to bring value to our community in the long term. You can find more information about AGPLv3 in this article.

Is Lago a payment service provider?
Billing API

Lago is an open-source billing API that helps you monitor usage, manage pricing plans and automate invoicing (among other things). We don't process payments but integrate with your favorite payment processors (e.g. Stripe Payments, PayPal, Paddle).

Lago automatically generates invoices that can be used to trigger the cash collection process. Invoices are available in PDF format or can be retrieved via webhook.

How do you generate revenue?
Billing API

Our priority is to generate value for our users and our community. We have started to think about monetization and our guiding principles are clear: we want a pricing that is fair, transparent and sustainable. We will not take a percentage of your revenue. Click here to learn more.

Who are you?
Billing API

We’re a nimble team who previously built from scratch and maintained a usage-based billing system for a fintech unicorn. At the time, we seriously underestimated the dozens of edge cases, engineering challenges, and huge impact on business teams (i.e. revenue growth, marketing, customer success, finance). We're now on a mission to build the tool we wish we had.

On top of that, we’re backed by Y Combinator, and some of the best open-source and fintech leaders.

How safe is it to use Lago?
Billing API

With Lago, your data never has to leave your infrastructure. Even if Lago had to shut down - which is definitely not our plan - your billing system would remain unchanged, as you would be able to host our open-source library.

Also, feel free to customize our API as much as needed, by forking our code: make your billing fit your needs instead of hacking around incumbent SaaS or worse, building your home-made system.