Let's get on each others' calendars.

How to Keep the SaaS COGS Turning:

The Key to Having Positive Cost Conversations

Before we start, this article might contain a few unfamiliar terms. To help you out, we’ve included a glossary of terms that you can refer back to as you’re reading.

Glossary of Terms

  • Cost of goods sold: The cost of goods sold (COGS) is the amount your business has paid to manufacture and deliver a product or service.
  • Gross profit: Gross profit, sometimes known as gross income, is calculated by subtracting the cost of goods sold (COGS) from the revenue (sales). It’s what’s leftover after the cost of delivering a product or service has been deducted.
  • Gross margin: Gross margin, sometimes known as gross margin percentage, is calculated by dividing the gross profit from the revenue. It is used to determine what percentage of the company’s sales income remains after product or service delivery to fund the business’ operations.
  • Direct cost: A direct cost can be directly linked to the production of a product or service. This is a cost included in COGS calculations.
  • Operational cost: An operational cost is an expense that’s incurred from the day-to-day running of a business. This is a cost that is not included in COGS calculations.

Tell me if this is familiar: Your company reports its finances monthly. And, the finance team, without fail, will ask you each month for more information about your AWS bill. The questions they ask are always overwhelming and confusing. You try to answer them as best you can, but later on, someone always gets on your case about why the margins have changed. But what do they mean? You haven't changed anything! They seem to think you’re responsible for reporting on costs and explaining why gross margins are up or down, but you feel unprepared and unable to explain why the margins are different. You just don’t know!

This is where your understanding of how to build an accurate COGS (Cost of Goods Sold) for a SaaS business becomes your lifeline.

As you probably know (but if you don’t, check out this article for a quick summarization), COGS is a financial practice that measures how much it costs a business to manufacture and deliver a product or service to its customers.

Now. For conventional businesses that sell physical products, let’s say one that makes tables, working out the COGS is a walk in the park. All the finance team would need to do is take an inventory at the beginning of the financial period, add the direct costs of manufacturing and delivering the tables to this amount (so these costs might include things like materials, labor, packaging, and delivery), take that sum off the inventory they’re left with at the end of the financial period, and hey presto! They have their COGS.

Easy, right?

But what about ‘non-conventional’ companies that don't make physical products? I’m talking about those that operate in the Software-as-a-Service (SaaS) space. For those finance teams, working out the SaaS COGS is a whole other ball game.

Because they’re dealing with software and applications, defining the direct costs involved in delivering SaaS products can be tricky: Costs are invariably variable due to the pay-as-you-go cloud computing model, there is little visibility over who is spending what when they’re delivering SaaS products, and it can be difficult for the often disparate and siloed finance teams to understand what counts as an operational cost (and therefore should be removed from the SaaS COGS equation) and what counts as a direct cost (and therefore should be included in the SaaS COGS equation).

But it’s essential that finance teams within SaaS companies get a firm grip over their COGS because it’s used to calculate the company’s gross margin which, in turn, proves the scalability of the business. A miscalculated COGS could spell disaster for a growing SaaS company.

So, what can you do to make sure the finance team gets an accurate COGS so you can explain the gross margin to the board?

Find out by churning your way through these topics:

  • Why you need to get your SaaS COGS calculation right
  • Which costs to include in your SaaS COGS (and which not to include)
  • How to calculate your SaaS COGS
  • The solution to keeping your SaaS COGS working

Let's get those SaaS COGS turning…

Why you need to get your SaaS COGS calculation right

Image of hands typing on a laptop. Overlaid is a hand-drawn series of math problems and graphical calculations.

The gross margin is the most important metric for a SaaS business. It gives you a snapshot of how financially healthy the business is and indicates its growth potential. The gross margin tells you how much money can be reinvested back into the business to help it grow.

“If you know your gross profit, you know how much excess revenue you have to service your overhead, rents, loans, and reinvestment. It’s one of the critical ways to see how well your business can manage the production process and its potential profitability.”

- SaaSholic, What is COGS for SaaS and How do you Calculate It

If you know your gross profit, you know how much excess revenue you have to pay to run your business operations and invest in growth strategies.

To get an accurate gross profit though, you first need to get an accurate COGS.

It works like this: To calculate the gross profit, the COGS is subtracted from the total revenue. The higher the COGS is, the lower the gross profit will be. And vice versa, the lower the COGS, the more gross profit the business will have to reinvest into growth.

Once you have your gross profit, the gross margin is a basic percentage calculation. You simply take the gross profit and divide it by your revenue. This creates a gross margin percentage.

For SaaS companies, you should be aiming for a gross margin of around 80-90%, which means that you should have a COGS that’s between 10-20% of the total revenue.

What happens if you miscalculate your SaaS COGS?

Photo of a man sitting at a desk wearing business attire in front of a computer. He braces his face on his hands, with his glasses sitting up on his forehead, appearing frustrated or overwhelmed.

If you miscalculate your COGS, it translates into an inaccurate gross margin. An inaccurate gross margin paints a warped picture of your company's financial health and will inevitably lead to bad decisions when it comes to making strategic plans for the company. For instance, a lot of SaaS companies will use COGS to make decisions on how much to invest in the delivery of their SaaS products during periods of rapid growth so they can remain profitable when growth slows.

A miscalculated COGS, that leads to an inaccurate gross margin, also affects the valuation: the process of determining how much the business is worth. A valuation demonstrates the profit capacity of the company and there are certain public market expectations for the gross margins of SaaS businesses. As an executive, you likely hold options for equity in your company, which means you have an interest in making sure the valuation (and therefore your stock price) is as high as it can be.

It can be useful to keep an eye on where you are in comparison to other companies by checking public company filings. There are plenty of aggregators, like Clouded Judgement who post aggregated statistics like the gross margins from the top 10 SaaS companies, with commentary, each week.

So, you can see why SaaS COGS must be calculated accurately. Any decisions based on miscalculated COGS (or revenue) could directly impact your own wallet down the line.

Which costs to include in your SaaS COGS (and which not to include)

For SaaS companies, the direct costs that should be included in your COGS are usually items that a customer will need once they’ve purchased the SaaS product. So they tend to be related to infrastructure and customer support.

Costs like these, for example:

  • Cloud hosting costs (for the production environment only)
  • Software licensing fees
  • Site reliability engineer wages (for those team members that keep the production environment running, not those that write the production or deployment code)
  • Software implementation costs
  • Training and onboarding costs
  • Customer support wages

Which costs shouldn’t be included in your SaaS COGS?

A good way to determine which costs to include in your COGS and which to leave out is to ask yourself this basic question:

“Can I still deliver this service if I don’t pay for this expense?”

If the answer is no, then that cost should be included. If the answer is yes, then the cost is probably an operational cost that isn’t directly related to the production or delivery of your SaaS product and should, therefore, be left out.

Operational costs, like these, for example, shouldn’t belong in your SaaS COGS:

  • Cloud hosting costs (any environments that are not customer-facing)
  • Administration costs
  • Product development costs, including software engineer wages
  • Internal operational costs
  • Acquisition costs
  • Rent or overhead
  • Insurance or legal costs
  • Sales and marketing expenses

But, it’s worth noting that whenever business operations change, companies will need to re-evaluate their COGS categorization and may need to restate their current or historic COGS.

For example, say an Account Manager's role was to sell SaaS products to customers. Their wages would be classified as operational costs, not COGS. But, if their role changed so they were now giving training to the users that had purchased the SaaS product, then you’d need to recategorize the Account Management wages from operating expenses to COGS.

How to calculate your SaaS COGS

Photo of a woman standing looking at a very large blackboard filled with an array of mathematical calculations and graphs.

Ok, so we need to address the rather large elephant in the room.

There is no mathematical formula that SaaS businesses can use to calculate an accurate SaaS COGS.

There. I’ve said it. It’s out there.

‘Conventional’ businesses tend to use age-old, tried-and-tested formulas to calculate their COGS, like the one below, for example:

COGS = Starting inventory + Purchases during the period (direct costs) – Ending inventory

This works perfectly for companies that make physical products and have a clear visibility and understanding of which costs directly contribute to the manufacture and delivery of their products, and which are merely operational.

But this equation doesn’t work for SaaS companies.

So, if there’s no COGS equation for SaaS companies, what’s the answer?

Well, it's up to you and your finance team.

Together you need to create a bespoke set of rules that categorize what counts as a cost incurred to deliver the SaaS product to the customer, and what counts as an operational cost that, therefore, needs to be accounted for elsewhere.

The finance team can then enter the cloud bills into the accounting system, allocating a subset of the expenses to COGS in accordance with the rules you agreed upon, and allocating the rest to operations. When it's time to do their financial reporting, the COGS costs incurred from cloud hosting, as well as other service delivery departments, are simply added up, a final amount is given, and they can use that figure to determine the gross margin accurately.

Then, when it’s time for you to present the financials to the board, having a shared set of COGS allocation rules will enable you to project changes to the gross margin, explain the reasons for any detected fluctuation, and offer appropriate alternatives accordingly.

Why does public cloud billing make SaaS COGS so hard to calculate?

SaaS businesses provide software-enabled services that are typically built in the public cloud (think AWS, Azure, or GCP) and delivered via the internet.

So, for a start, SaaS companies will rarely have an inventory that they can document at the start and subtract at the end of the financial period. So the traditional COGS equation falls flat on its face at the first hurdle.

But, a bigger reason why the trusty, old COGS equation won’t work in the SaaS space is because it’s difficult to determine which public cloud costs directly impact the delivery of the SaaS product and which don’t:

  • Due to the nature of the pay-per-usage cloud consumption model, the direct costs incurred when delivering a SaaS product are highly variable.
  • There is little transparency to finance teams over what cloud resources teams are using to deliver SaaS products, versus which resources are being used for development, testing, or research environments.
  • The finance team, that has to calculate the SaaS COGS, the detail provided in the monthly cloud bill provides no information regarding what business purpose each of the resources was used for.

This means that finance teams will often end up guessing what counts as a direct cost and what counts as an operational cost, and the valuation of the company is, therefore, usually inaccurate.  

The solution to keeping your SaaS COGS working

A close-up photo of a series of interlocking gears.

So we’ve covered how to calculate your SaaS COGS, what type of costs to include when working out your COGS, and why it’s essential to get your COGS figure right. But we still don’t know how to establish what the direct costs of making your SaaS product are. We’re still struggling with the variability of cloud costs, the lack of transparency and accountability for cloud spending, and the lack of understanding from the finance team over what costs are and how they relate to the delivery of the SaaS product.

So what’s the answer?

Call me biased, but the answer lies in Aimably.

The Aimably Advisor team has helped numerous companies develop their custom COGS allocation rules, specifically for the current state of their business. Once your accounting structure is in place, Aimably’s cloud optimization tools can help you break open fluctuations and trends, making them easy to understand and a lot easier to control for every team within the business, from the development team through to the finance team.  

How Aimably can help with your SaaS COGS

Aimably delivers cloud financial management services and software for businesses that use AWS cloud services. It has several offerings that will help finance teams get a deeper insight into what the development teams are spending (and why) to deliver the SaaS product. They can then use this information to categorize costs into either COGS or operating costs.

Every Aimably client starts with a cloud financial maturity assessment with an experienced cloud financial advisor. From this assessment, your Aimably Advisor will recommend a roadmap of initiatives, which may include developing new COGS allocation rules that are custom for your business operations and infrastructure. Once you are on the road to cloud financial maturity, the Aimably tools will keep your team on track.

With Aimably Pulse, for example, your engineering team can get daily spend fluctuation notifications for each AWS Member Account. This gives a level of transparency over even the smallest fluctuations in spending can keep costs stable and predictable over time.

Plus, the detailed spend reports that Aimably Insight offers, gives teams even more granularity when it comes to what people are spending on delivering the company’s SaaS products. They give a deeper insight into each individual element of your AWS bill, in historical context.

Find out what else Aimably and its features can do to calculate and control your SaaS COGS and help you have positive cost conversations with the board. Sign up for a free consultation with one of our AWS cost optimization experts who will discuss your situation and tell you how Aimably can help.  

SaaS Finances 101