Accounting for AI startups: model API spend, cloud credits and gross margin
An AI startup's books turn on three costs: cloud hosting, model API usage and the credits that offset them. Accountable categorizes each vendor charge with its reason, spreads annual commitments over the months they cover, and shows cost of revenue beside revenue so gross margin is one report. Model API calls that serve customers are usually cost of revenue, and how to present free credits is a judgment call for your CPA.
Updated · 4 min read · By the Accountable team
The short version
- Each cloud or model API charge is categorized with the reason shown, and a rule you tick once files every later charge from that vendor the same way.
- Cost of revenue sits beside revenue in Reports › Analysis, so gross margin does not wait for a spreadsheet.
- A $12,000 annual cloud commitment paid up front is spread as $1,000 a month with a Prepaid schedule.
- AWS applies credits to your bill until they are used up or expire, and Claude's API prepaid credits expire one year after purchase and are not refundable.
- Accountable does not read your cloud or model provider's billing directly; it reads the bank charge and finds the invoice through Gmail, Drive or forwarding.
Hosting and model API charges are vendor charges the books learn once
Connect the bank and cards that pay your cloud and model providers, free for Mercury, Brex and Ramp, and every charge is named and categorized with its reason. When the AI is not sure, it asks one short question, and ticking "Always do this for the vendor" turns your answer into a rule for every later charge.
| Charge | Usual category | What decides it |
|---|---|---|
| Cloud hosting for the product | Hosting and Infrastructure | Cost of revenue if it runs the product customers use |
| Model API usage that serves customers | Model API or software costs | Cost of revenue, as third-party software the product runs on |
| Model API usage for internal research | Research and development | Operating expense, not cost of revenue |
| Annual cloud commitment paid up front | Prepaid, then hosting | Spread over the months it covers |
The category names come from your own chart of accounts, and How to categorize business transactions has the cheat sheet.
Cost of revenue sits beside revenue, so gross margin is one report
Open Reports › Analysis and pick Spend, Revenue or Cost of revenue to see each by month, or read the Profit and loss. Gross margin is revenue minus cost of revenue, divided by revenue. Stripe's guide puts hosting and infrastructure, direct cloud costs, customer support and the upkeep of existing software in cost of revenue, and sales, marketing, administration and research on new features outside it.
For an AI product, inference that answers a customer is a cost of delivering the service, and work that builds new capabilities is usually research and development. Borderline cases, such as fine-tuning for one customer, are your CPA's call. The formula and benchmarks are in SaaS gross margin.
Annual commitments spread over the months they cover
When a provider wants a year up front, the bank charge is cash today and cost over twelve months. Create a Prepaid schedule under Accounting › Schedules with the total, the first month and the number of months, and Accountable also offers one when it spots an annual payment. A $12,000 annual cloud commitment starting March 15 expenses $1,000 a month for 12 months.
| What the bank shows | How it is booked | Who decides |
|---|---|---|
| Monthly cloud invoice, $4,200 | Expense in the month, categorized by vendor rule | The rule you ticked |
| Annual commitment, $12,000 | Prepaid, then $1,000 a month by schedule | You, from the contract |
| Prepaid model API top-up, $500 | Expense when bought, or Prepaid moved by usage with a journal entry | Your CPA |
| Credits applied on an invoice | Shown with the invoice; the bank charge is what you pay | Your CPA |
Credits change the invoice, so keep the invoice with the charge
AWS says credits are applied to your bill automatically until they are exhausted or they expire, and that the order depends on which expires soonest. Claude's API billing works the other way: you buy prepaid credits up front, they expire one year from purchase, all purchases are non-refundable, and you can set an automatic reload when the balance falls.
Practice differs on how to present free credits and prepaid balances, so Accountable does not choose for you. It keeps the evidence together: connect Gmail and Google Drive or forward invoices to your company's address, and each invoice attaches to the bank charge it explains, so your CPA sees the credit and the charge side by side.
Close the month with model spend in view
Step 1: Connect the bank and cards that pay your providers, and Stripe if customers pay you through it.
Step 2: Answer the first questions once and tick Always do this for the vendor, so each provider is filed the same way from then on.
Step 3: Create a Prepaid schedule for each annual commitment.
Step 4: Connect Gmail and one Drive folder so invoices attach to their charges.
Step 5: Close by the 1st and read cost of revenue and gross margin in Reports.
Questions founders ask
Do model API costs go in cost of revenue?
When the calls serve your customers, they are third-party software the product runs on, which belongs in cost of revenue. Usage for internal research is usually an operating expense. Your CPA decides the borderline cases.
How do I book prepaid API credits?
The bank charge for a top-up is categorized like any vendor charge. To make cost follow use, put the top-up on Prepaid and move each month's usage with a journal entry. Claude's prepaid credits expire one year after purchase and are non-refundable, which your CPA may weigh.
Does Accountable connect to AWS or OpenAI billing?
No. It reads the bank or card charge and finds the invoice through Gmail, Google Drive or forwarding, then attaches it to the charge.
Where do I see gross margin?
Reports › Analysis shows Revenue and Cost of revenue by month, and the Profit and loss has both. Gross margin is revenue minus cost of revenue, divided by revenue.
Books that show what your models cost
Start free with one company. Categorize every cloud and model charge with its reason, and read cost of revenue beside revenue each month.
Start freeSources, checked September 30, 2026: