442 points · by Rafsark · 3y ago · 141 comments
Our website is at https://www.getlago.com and our Github is here: https://github.com/getlago/lago.
We’re focused on composability (use only the parts you need), metering (measuring how much of a software service end users use, so that the service can charge them based on that), code transparency (we’re open source, so no black box - you can have a full understanding of how we built our API) auditable code, no lock-in into anyone’s ecosystem, and fair pricing (we don’t take a cut of your revenue).
We’ve been in Fintech for more than 7 years, and were the earliest employees at Qonto.com (SMB Neobank in EU), where we built and scaled the billing system and led the revenue team that took the company from pre-launch to $100M+ of ARR.
Back in the early days at Qonto, our pricing was very simple, a single “all-included” subscription. We budgeted 3 months of a single back-end to “get it done, once and for all”. As we shipped new features (add-ons, new tiers, usage-based etc), improved the packaging, changed our reporting structure as we matured (or instance, we changed the billing cycles from anniversary dates to calendar dates which looked trivial until we had to migrate 100K+ companies), launched new countries (new prices, new taxes implications new reporting!), we iterated on pricing dozens of times.
We consistently underestimated the engineering nightmare billing would create, and learned the hard way about side effects: delayed launches at best, billing errors at worst, resulting in churning users. We wrote an article about this that had a large HN thread last year (https://news.ycombinator.com/item?id=31424450).
We tried to get rid of our home-grown system many times but never found an alternative that was flexible enough. As a result, there were only two options: either stop iterating on pricing and leave revenue on the table, or grow a billing engineering team. We chose the second, but it was expensive. Finding pricing or monetization experts living in spreadsheets is easy, but finding technical professionals to build and maintain a billing system is a real bottleneck. Few engineers or product managers have experience in billing, and it’s rarely a career path they look forward to.
At some point, we realized we’d stopped being able to do pricing strategy based on what was best for the company and found ourselves driven by what was easiest to implement—not because we wanted to, but because it was all too complicated. We asked around and realized a lot of companies were in a similar situation. There are a lot of clunky internal billing systems out there! We spent a lot of time analyzing why no one had solved this problem, as we thought companies like Stripe or Chargebee had partially addressed it. We came to the conclusion that a proper solution needed to be open source.
A lot of teams continue to build their billing system themselves because they have unique edge cases that closed-source solutions can’t address. They are part of the “long tail”, which a closed-source SaaS has no incentive to invest in solving. That’s how we arrived at the idea of open sourcing “core billing” foundations that other people could use and build on. We don’t solve 100% of use cases either, but what we don’t solve, others can build, without having to reinvent an entire system. We think of Lago’s features like “Legos” you can pick to build your own system, rather than a “one size fits all” billing platform.
Unlike closed source solutions, we aim at giving full transparency on how Lago works (auditable code), and enable our users to pick only the parts of our product that are relevant to their needs (e.g., if they are already handling subscription management but want to manage prepaid credits with Lago, they can). You can make your own design decisions, build anything custom that you need, and collaborate with other engineers in the community.
For instance, one of our users built a Javascript SDK that is now available to everyone. Others are developing additional “charge models”: for instance we don’t offer the ability to “cap a charge” yet: if you’re a fintech processing transactions, you’d like to bill for instance “2% of the transaction amount capped at $50”, to make your pricing attractive. We’re working with a team who are contributing this to Lago. Other contributions involve adding native integrations with local payment processors (in India, Northern Europe, Africa, Middle East), because they usually cater better to the needs of local players in these regions: better payment success rates, better conversions at checkout pages, and usually better prices.
We’re making Lago as open as possible to adjacent tools (e.g., payment processors, quoting software, CRMs, etc.)—both market leaders and niche solutions in smaller markets. We’ve built native integrations with GoCardless and Stripe Payments, but our API is usable with any payment processor from any region, and some community members are already doing so.
We’re also partnering with Osohq.com, open-source as well, that manages authorization and entitlements (granting access to a specific feature if a user had subscribed to a specific plan): https://doc.getlago.com/docs/integrations/entitlements/oso You can also use Lago with automation tools like n8n.io to create workflows, for instance if you notice your end users have an unusually high consumption of your product, and you want to avoid “bill shock”, you might want to alert them or your customer success team to take proactive actions: https://doc.getlago.com/docs/integrations/alerting/n8n#overc...
We’re actively working to build an ecosystem around Lago and address the long tail of edge cases that makes billing and monetization complex, with the help of the community.
How it works: Lago collects HTTP events sent by a backend application. These events are automatically aggregated to create “units to be charged”. Each unit can be priced using different pricing models (tiers, packages, percentages). At the end of each billing period (month, quarter, year), a worker gathers all the fees into an invoice (PDF or JSON webhook message). The issued invoice can be connected to various services (payment providers, accounting tools, CRMs) and edited with discounts or credit notes to adjust it.
Once the back-end events are sent to Lago, non-technical users can use our user interface and manage pricing without help from engineers. This is what our UI looks like: https://youtu.be/dXnoMRetsr4
Lago is self-hostable and you can download a Docker image here: https://github.com/getlago/lago. We also have a cloud product that is being used in production. For now we’re still granting access manually, but we’ll make it generally available in the near future. In terms of pricing: the self-hosted product, which contains the core billing features, is free. We’ve tried to make it featureful enough for a business to just use the free product and build what they need on top of it. Premium (i.e paid) features currently include billing on different time zones, credit notes, and will include Salesforce integration in the future. Beyond that, we’re still working out our approach to pricing and have written some of our thoughts about it here: https://www.getlago.com/blog/how-we-think-about-our-own-pric....
The billing / monetization is space is huge and we’re continuing to learn every day, so we would greatly appreciate and are (nervously) eager for your feedback! Thanks!
We started as usage-based then learned a few years in (once we understood customer usage trends - key) that customers would gladly pay ~20% MORE per year for unlimited access because the customer wanted a predictable bill. We essentially rode the same trend of pay-as-you-go mobile to unlimited plans.
Later in our history we found investors (and our accountants) liked the predictability as well. It's easier to show "up and to the right" when not dealing with a few large customers varying down in usage in one quarter (even if the business was on the upswing).
One-size doesn't fit all -- usage billing has its place for sure -- just carefully weigh your model as it's a huge lift to flip it midstream.
Customers start out by wanting all the flexibility (for their devs, usually) to spin up their owner servers, and want used-based billing. It would be a waste to pay more, no?
Then their own book keeping department yells at them, because they use SAP, and every bill that differs from the contract or the previous month is sheer hell and requires 5 levels of approval / justification / whatever.
So the next iteration is that they buy a fixed contingent of "cloud points" per month so that the invoice remains constant, and there's reporting and/or a firm (but often unwritten) promise from the account manager that they'll notify the customer if/when they ever run the risk of exceeding their contingent.
In really big / inflexible companies, it really seems to be easier for the purchasing managers to justify higher but constant prices than variable prices. The inefficiency boggles the mind.
So true. At one point Google Ads had a BillingCap enum in their APIs, used to set up "capped actuals", a scheme also known as "monthly with rollover". Something that I understood as selling monthly quotas of a consumable, or as you put it, "cloud points".
My notes points to: https://developers.google.com/ad-manager/api/reference/v2019... . But this URL is broken and I can't find any trace of "capped actuals" anywhere in Google's documentation. I guess it was probably rebranded/refactored into budgets/monthly spending limit/monthly invoicing/whatever.
At the end I think "points" is a better way to sell this feature. If this is generic enough, it can be an answer to airlines' miles and similar loyalty programs the retail industry is fond of.
If you’re solving a problem that a typical customer experiences let’s say 3x per week (perhaps routing an inbound sales lead to a CRM), you could charge per use, or ask “If we made it unlimited, would they use it 5x per day? 10x per day?”
With many SaaS products, usage is self-limited by the customer’s actual need, not by a transaction cost. Same goes with most telephony use cases - a typical user will only make so many calls per day, making it relatively easy to arrive at an unlimited monthly price.
(i) "pure usage based pricing" models (like Snowflake's) aren't going to be the main standard for SaaS, for the reasons you mentioned, the main being predictability (for the merchant and the end-user). Cash collection is also a big pain: if you collect cash after the consumption, the dispute rate can be high. (ii) However pricings will increasingly incorporate "usage dimensions" (monthly active rows, number of emails, GB used, etc) and this trend is spreading very fast (3 out of 5 SaaS according to the latest OpenView report). It can take many forms: Annual subscriptions including a monthly base usage and/or prepaid credits based on consumption, and/or an amount of payments processed, etc This is what we lived at Qonto.com and solved for, for 4 years, and you woudn't think of it at a "usage based player" though, we rather had "usage subscriptions" : https://qonto.com/fr/pricing All the possible combinations make the billing very hard to maintain and iterate on, and this is why we built Lago. All this to say, we 100% agree with you that not all companies should choose a "full usage based pricing" but find a balance or at least iterate between "subscriptions/fixed amount" and "usage based".
I think it's funny how MBA's at the end of the day base their decisions on glancing at a chart. So now, the engineers are catching on to optimizing for that pretty chart.
I made a mistake by spitballing sales figures for a product and someone incorporated it into an ROI calc that was being judged to the decimal place.
https://news.ycombinator.com/item?id=34773891
https://www.getlago.com/blog/open-source-licensing-and-why-l...
>Case 1: You fork our code to build your own billing system at your company. It’s awesome and we would be grateful if you could take some time to share your code as well, as it could help other companies. This is _strongly encouraged but not required_, as we understand not all companies can afford to do this.
And later in the quoted explanation of AGPL:
> "If you run a modified program on a server and let other users communicate with it there, your server must also allow them to download the source code corresponding to the modified version running there."
If you fork the project, your company's customers are communicating with your forked code. So are you required to publish your forked changes? Only required to share the fork with paying customers? Or as your desired case states, not required?
(In any case, Lago looks very cool. Thanks for pushing forward the conversation on open licensing!)
I think what matters more is how the creators of the software intend the license. In case of Lago it's clear they want you to use it this way, and AGPL is only really meant to restrict businesses that want to fork it and start a proprietary billing service.
Restricting your usage tracking to your users is fine until you start shouting to them directly on their phones.
Of course, the vendor/distributor/consumer model can become vendor-many-clients through simplication, same ideas hold.
As it turned out, the company was lucky to have some data-storage-discovery-and-inventory software built as part of the bigger eventual vision that attracted a buyer. It was not the time to work on ambitious greenfield stuff, I guess. The patents were not relevant to the acquirer, and they lapsed at some point.
https://patents.google.com/patent/US20030083998
https://patents.google.com/patent/US20030084000
https://patents.google.com/patent/US20030083892
https://patents.google.com/patent/US20030083995
https://patents.google.com/patent/US20030083994
https://patents.google.com/patent/US20030084145
https://patents.google.com/patent/US20030083999
https://patents.google.com/patent/US20030084060
https://patents.google.com/patent/US20030084343
https://patents.google.com/patent/US20030084341
[edit: 2000 -> 2000/2001 ... "any patent issues" --> "many patent issues" ... a few other in the inventory of ideas ... simplification of model to vendor-many-clients ... fixed one link]
Per-seat pricing has always felt annoying to me. Ideally you want everyone at your company to be able to access the tools that everyone else uses (you don't want to create a bunch of second class citizens), but that gets really expensive really quickly. So per-user-per-month has never felt great to me.
That said, usage-based billing is confusing. And when customers are confused, they simply chargeback the credit card charge. AWS can make it work, but I'm not sure if everyone else can. Will be interesting to see.
I remember having to negotiate with Stripe the removal of their lowest limits. The quantum of unit I was billing on my cloud platform was such that you could consume just enough CPU and storage to end up with a $0.01 invoice at the end of the month.
It was impossible for Stripe to process this payment. IIRC their lowest limit was $0.50 or $0.10. I guess they had this limit in place to prevent abuse and limit fraud. As we had similar hard-coded heuristics for the same reasons.
My most recent Rackspace bill was $0.05. I don't even remember what I'm using it for any more, but it's not worth it to check out.
My last Pulumi bill was $0.86.
this is not good faith B2B behavior. i'd be surprised if 1% of B2B usage based billing customers behave like this.
It's something you have to expect, and kind of gauge how much money the customer has and send them lots of email as they approach a limit, and make it very clear in the UI that money is being spent that they will soon have to pay. Even then, who knows what people will do. It's bad faith on their part; you, the service provider, are the ones penalized.
I agree that usage-based billing can be difficult to predict revenue from. We don't think companies will switch entirely to this model. However, the hybrid model can be beneficial for both customers and vendors. Companies can charge a base platform fee and then charge for overage instead of blocking it. This could increase revenue for companies that currently use subscription-based billing.
Strong vibes of the dot-com era reading the description but there's probably one or two insights there worth revisiting. Ordered! :)
But then I've noticed that you use git submodules for the frontend and backend. It's actually a Rails application from what I can tell.
The billing part was easy to build (though of course we under-estimated the effort by 10x), but the reporting is the really tricky part. Revenue recognition, plus simple things like correctly tracking upgrades/downgrades vs expansion/contraction when someone changes plan mid-month.
Is this something that Lago does now or intends to include? I could not see it in the docs.
And as you say, everyone kept telling us "Can't you just use Stripe or Chargebee?" but the answer was always no.
I will definitely check this out next time I'm setting up a billing system!
First, congrats on the launch Lago. I've been very impressed with your ability to educate devs about the intricacies of billing and you are certainly pushing the entire space forward.
While you offer coupons and credit notes, there are features you don't have that we have prioritized and built, including, usage alerts, plan versioning, gauge metrics, custom sql etc. etc. Point being I think its unfair to say we are a subset of your product.
In addition, we have a 25+ year billing expert on our team who has been CTO of a startup processing $300 million a year.
Lastly, I don't think it's fair to make statements about our customers just because we haven't "announced" them yet.
Happy to chat more with anyone about our differences.
First of all, we launched our open source billing repository months before they did. In fact, they even reached out to us for inspiration. This could be related to the fact that our team has prior experience building billing engines, so we have a better understanding of the space.
From a product perspective, our coverage is more extensive. We provide more advanced coupons, usage-based components and billing use-cases. For example, we offer credit notes and refunds, small examples that are not listed in their API. Our product covers more billing edge-cases and deeper features.
Finally, we have customers in production. Our top user is invoicing 5M customers a month, which might not be the case for them.
To conclude, I would assert that we are more advanced.
Focus on why your product is better or different and not these factors like who was early, who has more experience with billing engines etc because again, experience doesn't translate to success necessarily.
All the best.
With our open source version of Lago, we offer: - Fair pricing: scale your billing as your company grows - Composability: build the pricing/billing you have in mind, without the limitations of vendors - Participative approach: contribute to the entire billing engine so other companies can benefit from it.
Which of those is the smallest negative depends on your product.
Any plans to tackle Stripe Connect like functionality (platform / marketplace payments)?
I'll explore the product more on my own and will try to contribute back where possible
I wonder, would it ever be possible to use the structure provided by lago to also set up a marketplace where user can buy/sell from eachother?
Lago is completely agnostic of payment providers, meaning you can use any payment service provider (PSP) with it, whereas Stripe requires the use of its entire stack.
Lago is event-based, making it easy to ingest a high volume of usage-based components. This eliminates the need for users to manually bill their own usage-based billing aggregation on top of Stripe.
Lago is open-source, so there is no revenue taken as a cut. For its fully cloud-hosted version, Lago prices a platform fee and tiers on usage-based events, making it more scalable for high-volume companies. Additionally, its open architecture allows for full customization to fit your needs.
>> The tech stack we use to build Lago (YC S21), the open source billing API (https://news.ycombinator.com/item?id=32438355)
>> Lago: The Open Source Stripe Billing Alternative (https://news.ycombinator.com/item?id=32438355)
>>Lago: The Open Source Stripe Billing Alternative(https://news.ycombinator.com/item?id=31638797)
>>Show HN: 6 Steps to build a usage-based billing system with Lago (YC S21)(https://news.ycombinator.com/item?id=32765162)
>> Show HN: Lago: Open-source metering and usage-based billing (https://news.ycombinator.com/item?id=33505229)
Our previous articles focused on billing-related content. They discussed various aspects of billing, such as Stripe fees, alpha launch, and various features.
YC video about launching and launching again.
We're also working in the billing space with a complementary tool, Tier (https://github.com/tierrun/tier). Although we currently do not support Lago directly, it's exciting to see more options emerging. Their content marketing has been particularly impressive on HN and in general.
With metering, entitlement management, CPQ, feature gating, and everything else required in a modern SaaS company, the PriceOps space can be quite complex for developers.
Congratulations on the launch and best of luck!
Want to say Thank you for putting all artefacts online. Same applies to Lago!
Admire your focus on Stripe and beginner friendly approach from the day one
https://github.com/tierrun/tier/blob/main/pricing/schema.jso... https://docs.tier.run/docs/resources/mapping-to-stripe https://github.com/tierrun/tier/wiki/Stripe-Glossary
Lago backend is built with Ruby and GraphQL ... which is kind of deal-breaker for me. No time to invest in Ruby ecosystem. I'm only using opensource products which I can fork and debug later on. https://github.com/getlago/lago-api/tree/619a7a53f98d9a19908...
Lago is much closer the production ready however. Solid stand-alone tool already.
Tier like projects gives me hope to give SaaS user better embedded billing experience and more control in the future.
My biggest scare - successful open source projects are getting too many extraline of code overtime.
Ex. Sentry with 25+ containers inside https://github.com/getsentry/self-hosted/blob/48c855aa3def45...