What Counts as Cost of Goods Sold for an AI Company

Turn this article into takeaways for your work.

Each assistant summarizes the article only for you and suggests best practices for your work.

Cost of goods sold (COGS), also called cost of revenue, is the cost of delivering what you sold. For a bakery that's flour and ovens. For an AI company it's the compute, hosting, review work and support that happen every time a customer uses the product. Everything else, including the cost of building the next version, belongs in other lines.

That sounds simple, and it mostly is, until you look at how an AI company actually spends money. The same GPU cluster can serve customers on Monday and train a new model on Tuesday. A human reviewer can check a customer's output or label data for the next release. Where each dollar lands decides your reported gross margin, and gross margin shapes how investors value you and how your numbers compare with everyone else's.

This guide covers the accounting definition: what goes into cost of revenue, what goes into R&D and sales and marketing, how public companies describe it, and where the gray areas are. It doesn't cover the mechanics of cost per request or ways to lower it. Those live in AI inference costs and gross margin and AI model cost management.

The three buckets

Most income statements sort costs into three groups. Understanding the boundary between them is the whole game.

Cost of revenue holds the costs directly tied to delivering the product or service to paying customers. If the cost goes up when usage goes up, it probably belongs here.

Research and development (R&D) holds the costs of creating or improving the product. Under US accounting rules, research is defined as planned search or critical investigation aimed at discovery of new knowledge useful in developing a new product or process, or in significantly improving an existing one (the FASB's ASC 730 wording, as compiled by the National Center for Science and Engineering Statistics). The key idea is that the spending creates future capability rather than serving today's customer.

Sales and marketing (S&M) holds the costs of finding and winning customers: advertising, sales salaries, commissions, events, and the free usage you give away to attract buyers.

A fourth bucket, general and administrative, covers finance, legal and executive costs. It matters less here.

What the rules actually say

The formal rules are thinner than most founders expect. The SEC's Regulation S-X, which governs public company financial statements, says income statements must state separately the cost of tangible goods sold, cost of services, and expenses applicable to other revenues. It also provides a separate caption for other operating costs and expenses. That's it. There's no list telling an AI company whether inference belongs in cost of services.

So classification comes from principle plus company judgment. Companies describe their policy in the notes and in the management discussion of their annual report, and auditors check that the policy is applied consistently. That's why reading actual filings is more useful than reading a rulebook. We'll do that below.

Classification table

Here's how the common AI cost items usually sort. "Usually" matters: the right-hand column flags where a reasonable company could land elsewhere.

Cost item Typical bucket Why Gray area
Inference compute serving paying customers Cost of revenue Incurred each time the product delivers a result Inference used by your own engineers for testing belongs in R&D
Cloud hosting and storage for the live product Cost of revenue Required to keep the service running Shared environments need an allocation method
Third-party model API fees for customer requests Cost of revenue A direct input to each delivered answer Fees for internal experiments go to R&D
Human review that is part of delivering the service Cost of revenue The customer is paying for output that includes the review Review done only to improve the model is R&D
Data labeling for model improvement R&D It builds future capability Labeling that is really customer-specific delivery work may be cost of revenue
Training runs and fine-tuning for new models R&D Creates a new or improved product Customer-specific tuning delivered as part of a contract can be cost of revenue
Research staff and experiments R&D Discovery of new knowledge None, this is the clear case
Customer support Cost of revenue Supports customers already paying Some companies place pre-sale support in S&M
Onboarding and implementation Cost of revenue Delivering what was sold Free onboarding for prospects may be S&M
Payment processing fees Cost of revenue Charged on each transaction Rare to see it elsewhere
Monitoring, security and reliability engineers for production Cost of revenue Keep the live service running Engineers who build new features are R&D
Free tier and trial usage Varies (S&M or cost of revenue) Acquisition spend versus delivery of a service Policies differ, so disclose yours
Sales commissions and advertising S&M Winning customers None

Notice the pattern. The question isn't "what kind of resource is this?" but "what was it spent on?" A GPU hour is a GPU hour. Serving a paying customer makes it cost of revenue. Training a new model makes it R&D.

What public filings show

Public software companies that sell AI features give the best evidence, because they have to explain their policy in writing. The wording below comes from each company's most recent annual report available.

Adobe says its cost of subscription revenue consists primarily of third-party hosting services and data center costs, including AI inferencing costs, along with compensation for network operations, implementation, account management and technical support staff. On the other side, its R&D expenses include hosting services and data center costs including AI training costs. That's the cleanest split you'll find: inference in cost of revenue, training in R&D.

Atlassian describes cost of revenues as third-party hosting fees, including cloud infrastructure and AI inference incurred through customer usage of its AI tools, plus employee compensation, amortization of acquired developed technology, payment processing fees, and contractor costs for customer support and infrastructure teams. Its R&D line also lists third-party hosting fees, including cloud infrastructure and AI inference. So inference shows up in both, split by who used it: customers (cost of revenue) or the company's own development teams (R&D).

Duolingo says its cost of revenues predominantly consists of third-party payment processing fees in addition to hosting fees and AI costs, and, to a much lesser extent, customer support costs. Payment processing is a reminder that cost of revenue for a consumer subscription product can include a large non-AI item.

Three different companies, three different mixes, one shared logic: costs of serving customers sit in cost of revenue, and costs of building the product sit in R&D. If you're drafting your own policy, use the same test and describe it plainly in your financial notes.

The training question

Training is where opinions diverge, so it deserves its own section.

Under the R&D logic, a training run builds a model that will serve many customers over many months. It's an investment in the product, not a cost of serving any single customer. Adobe's disclosure follows this approach.

The counterargument is that for companies whose main product is the model itself, training is not a one-off project. Retraining is ongoing. a16z noted early on that training a single model can cost hundreds of thousands of dollars or more in compute, and that retraining is increasingly seen as an ongoing cost, because the data feeding the model changes over time. If you must retrain to keep the product working, it starts to resemble maintenance of the thing you sell.

Investors have settled on a practical convention, even if the accounting rules don't force it. Analysts at Epoch AI, for instance, compute gross margin as revenue minus inference compute and treat R&D compute as a separate line, attributed to developing the next model rather than recouped by the current one. Note that this is an outside analysis built on estimates, not audited financials. But it shows how investors tend to frame things: inference in margin, training in the investment line.

The takeaway for a founder is to pick a policy, apply it consistently, and be ready to show the number both ways. A sophisticated investor will often ask for gross margin with and without any training costs you've placed in cost of revenue.

Why the classification matters

Gross margin. Move a large cost from R&D to cost of revenue and gross margin falls, with operating profit unchanged. Move it the other way and gross margin looks healthier. Because gross margin is a headline metric, the classification choice is never neutral. If you want a refresher on the metric itself, see our guide to gross margin.

Valuation. Software investors have long paid for high gross margins, because they signal that each new dollar of revenue is cheap to serve. a16z observed that AI companies often show gross margins of 50 to 60 percent, against 60 to 80 percent or more for traditional SaaS. Misclassifying a delivery cost as R&D inflates your margin and, with it, any valuation built on a margin multiple. That tends to surface in due diligence, and it damages trust when it does.

Comparability. If two companies in your category classify differently, their margins aren't comparable. Investors normalize by reading the notes, but you make their job easier by disclosing what's in each line.

Unit economics. Cost of revenue feeds your contribution margin and your unit economics. If delivery costs hide in other lines, you'll underprice your product and discover it too late. Our guide to SaaS economics and unit metrics shows how these ratios connect.

Pricing. The cost base you report is the floor under every pricing decision. Whether you charge per seat, per use or per outcome, you need to know what one unit of delivery costs. See usage-based versus outcome-based pricing for AI for how that plays out.

Key Facts: AI Company Cost of Revenue

Human review and labeling

Humans in the loop are the most commonly misclassified item. a16z flagged two forms: data labeling and real-time human review. They look similar but sit in different places.

Suppose a claims-processing product has staff verify every output before it reaches the customer. That review is part of the delivered service, so it belongs in cost of revenue. If the same staff relabel disputed examples to improve next quarter's model, that work builds future capability and belongs in R&D. When one team does both, track their time or allocate on a documented basis.

The point matters for margin trajectory too. Early agent-style products often rely on heavy review that fades as the system improves. If that review sits in cost of revenue, you can see the margin improve as review shrinks. If you buried it in R&D, your margin looks artificially good now and then shows no progress later, which weakens the story you tell investors about scaling.

Practical steps for a founder or finance lead

Write down a one-page cost classification policy before your first audit or fundraise. It should cover:

  1. Inference and hosting. State that production usage is cost of revenue and internal development and testing usage is R&D, and say how you measure the split (tagging, separate accounts, or usage logs).
  2. Third-party model fees. Do the same for API charges from model providers: customer-driven calls go to cost of revenue, experiments to R&D.
  3. People. Map support, onboarding, reviewers and production engineers to cost of revenue. Map product, research and feature engineers to R&D.
  4. Training and tuning. Decide whether general training is R&D and whether customer-specific tuning delivered under contract is cost of revenue. Write the reasoning down.
  5. Free usage. Decide whether free tiers and trials are S&M or cost of revenue, and stay consistent.
  6. Disclosure. Describe each line in your reporting package so a reader can recompute margin on a different basis.

Revisit the policy when your business changes. A company that starts selling fine-tuned models to customers has a new kind of delivery cost, and the old policy may not fit. For the business model context that drives these choices, see AI startup business models explained.

Common mistakes

Using one blended cloud bill. If production and experiments share an account with no tagging, you can't classify anything. Separate them early.

Treating gross margin as a cosmetic number. It drives pricing, valuation and hiring plans. Moving costs around to flatter it creates problems later.

Ignoring support and onboarding. AI products often need more hand-holding than classic software. Those costs belong in cost of revenue and can be material.

Changing policy without telling anyone. A reclassification shifts margin overnight. If you change policy, restate prior periods so trends stay meaningful.

Assuming public companies are a template. The filings above come from large software companies with established finance teams. Early-stage startups often have messier data. Use them as a model of logic, not a promise that your numbers will look alike.

Frequently Asked Questions about AI Company Cost of Goods Sold

Is AI inference cost of goods sold?

When the inference serves paying customers, yes. Adobe, for example, lists AI inferencing costs within cost of subscription revenue. Inference run by your own engineers for testing or development is normally R&D instead.

Is AI model training a COGS or R&D expense?

Most companies treat training new or improved models as R&D, because it builds future capability rather than serving a specific customer. Adobe's filing places AI training costs in R&D. Some companies that must retrain constantly to keep the product working argue for a different treatment, so write down your policy and apply it consistently.

Do customer support and onboarding count as cost of revenue?

Generally yes, because they support customers who already pay. Atlassian and Duolingo both include customer support costs in cost of revenues. Pre-sale support or free onboarding for prospects is sometimes classed as sales and marketing.

Does human review of AI output count as COGS?

If the review is part of delivering the service to the customer, yes. If the same work is labeling data to improve a future model, it's R&D. Track or allocate time when one team does both.

Why does COGS classification affect valuation?

Gross margin is a headline metric, and investors have historically paid more for higher-margin software. a16z found AI companies often show 50 to 60 percent gross margins versus 60 to 80 percent or more for SaaS. Classifying delivery costs as R&D flatters that figure and tends to unravel in diligence.

What does the SEC require for cost of revenue?

Regulation S-X requires cost of tangible goods sold and cost of services to be stated separately, with other operating costs reported apart. It doesn't tell AI companies where inference or training go, so each company sets and discloses its own policy.

About the author

Brian Tr

Brian Tr

Co-Founder & COO

Brian Tr is Co-Founder and COO of Rework, with 12+ years in B2B go-to-market and operations. Brian scaled Rework from 0 to 10,000+ B2B customers across CRM and productivity tools. Brian writes for founders and owner-CEOs: startup fundamentals, founder-led and family businesses, partnerships, and how SaaS, marketplace, AI and EdTech companies grow.