Contents
What is the difference between CapEx and OpEx? What are examples of CapEx and OpEx? How do you calculate CapEx and OpEx? What are the advantages and risks of each spending model? Is cloud computing CapEx or OpEx? Is AI spend CapEx or OpEx? When can you capitalize software and AI development costs? How do finance teams decide between CapEx and OpEx? Frequently asked questions about CapEx and OpEx

Quick Answer

CapEx is money spent on long-term assets like servers, buildings, and GPU clusters, capitalized on the balance sheet and depreciated over years. OpEx is day-to-day spending like salaries, subscriptions, and API usage, expensed immediately. Cloud and AI consumption is usually OpEx, while owned AI infrastructure is CapEx.

On July 22, 2026, Alphabet reported quarterly revenue of $119.8 billion, up 24% year over year, with operating margin expanding to 34%. It was the company’s 12th consecutive quarter of double-digit revenue growth. The same release showed free cash flow of negative $5.9 billion.

Operations generated $39.1 billion in cash that quarter. Purchases of property and equipment consumed $44.9 billion. Alphabet also raised $49.6 billion in equity, earmarked in part for capital expenditures that scale AI infrastructure. Nothing about the business weakened. The spend changed lines.

The textbook distinction between capital and operating spending hasn’t changed in decades.

What changed is the spend itself: AI moved billions across that line in both directions at once, and finance teams are discovering that classifying it correctly is now a measurement problem before it’s an accounting one. That argument runs through everything below.

What is the difference between CapEx and OpEx?

Capital expenditure (CapEx) is money a business spends to acquire or improve assets that keep providing value beyond the current year: buildings, servers, networking hardware, GPU clusters, patents. Operating expenses (OpEx) cover the day-to-day running of the business: salaries, rent, subscriptions, and consumption-based services that get used up as you pay for them.

The two categories live in different places in your financial statements. Capital spending lands on the balance sheet as an asset and reaches the income statement gradually, as depreciation or amortization spread across the asset’s useful life. Operating spending hits the income statement immediately, in the period you incur it.

The distinction decides when spending hurts reported profit, which deductions you take this year versus over a decade, and whether a growing AI bill shows up as investment or as margin erosion. Two companies with identical AI spend can report meaningfully different gross margins purely on classification.

What are examples of CapEx and OpEx?

Buildings, owned hardware, and GPU clusters are classic capital expenditures. Salaries, subscriptions, and pay-as-you-go cloud services are classic operating expenses. The dividing line is whether the purchase creates a long-lived asset you own or covers a cost consumed as the business runs.

The same purchase can even shift categories over its life. A software license bought outright is capital spend, while the annual support contract attached to it is operating spend. A server is capital spend when purchased, and the electricity, cooling, and staff time that keep it running are operating spend from the first day.

Here’s how the two models compare side by side:

CapExOpEx
Stands forCapital expenditureOperating expenses
What it buysLong-term assets with multi-year useful lifeDay-to-day operations consumed within the year
How it’s paidLarge upfront payment, from cash or debtPay as you go, covered by income as it occurs
Financial statementBalance sheet asset; reaches the income statement as depreciationIncome statement expense in the period incurred
Tax treatmentDepreciated (tangible) or amortized (intangible) over useful lifeFully deductible in the year incurred
Cash flow impactTies up cash now, spreads P&L impact over yearsPreserves cash flexibility, hits P&L immediately
Traditional examplesBuildings, servers, networking hardware, patentsSalaries, rent, marketing, software subscriptions
Cloud examplesBuilding a private data center; buying dedicated hostsAWS, Azure, and GCP consumption; SaaS licenses
AI examplesPurchasing GPU clusters; on-premises training infrastructurePer-token API usage; AI subscriptions; managed inference
Approval patternLong planning cycles, executive sign-offDecided close to the work, often by the teams doing it

How do you calculate CapEx and OpEx?

Capital expenditure is derived from the balance sheet and income statement together:

CapEx = Current period PP&E − Prior period PP&E + Depreciation (current period)

If your property, plant, and equipment grew from $2 million to $2.4 million and you recorded $300,000 in depreciation, your capital spending for the period was $700,000.

Operating expenses are simpler to total:

OpEx = COGS + Operating expenses

In practice, operating expenses are every cost on the income statement above operating income: the direct cost of delivering the product plus the cost of running the company around it. For SaaS companies, separating cost of goods sold from broader operating expenses matters enormously, because COGS determines gross margin, the number investors read first.

Alphabet’s Q2 2026 statements show the arithmetic at full scale. Property and equipment purchases of $44.9 billion against $39.1 billion in operating cash flow produced quarterly free cash flow of negative $5.9 billion. A year of capital spending compressed the company’s trailing twelve-month free cash flow to $53.3 billion.

The quarterly sequence tells the story even more clearly. Alphabet’s free cash flow ran $24.5 billion in Q3 2025, $24.6 billion in Q4 2025, $10.1 billion in Q1 2026, then went negative in Q2. Revenue grew the entire time. The classification of the spend, not the health of the business, reshaped the cash picture.

What are the advantages and risks of each spending model?

Capital spending buys control and predictability at the price of flexibility. Operating spending buys flexibility at the price of predictability. Most of the practical trouble finance teams run into comes from underestimating the second half of each trade.

Owning assets means owning their upside: no vendor dependency, full control over security, and a cost that is fixed once the purchase clears. It also means committing cash that cannot fund other work, estimating capacity years ahead, and accepting lock-in. Technology that advances faster than the depreciation schedule leaves you paying for capacity you would not buy again.

The operating model removes those commitments and introduces new exposure. Usage-based spending flexes with demand, frees cash flow, and hands maintenance to the vendor. The model is also inherently harder to predict, because thousands of small consumption decisions replace one large approved one.

Allocation is the quieter risk on the operating side. When usage-based spending can’t be traced to the customers and features consuming it, COGS gets misstated, gross margin gets misstated with it, and the business ends up making pricing and investment decisions on numbers that don’t reflect reality.

AI consumption amplifies every one of those operating-side risks. Token-based billing scales with success: the better a feature performs, the more it gets used, and the larger the untracked line grows. The adoption win and the spend problem are the same event, which is why classification and measurement have to be designed together.

Is cloud computing CapEx or OpEx?

Cloud computing is generally operating spend, because you pay for services on a subscription or usage basis instead of buying infrastructure outright. Moving from an owned data center to the cloud is, in accounting terms, a migration from the capital column to the operating column.

The classification gets murkier at the edges. Multi-year reserved commitments, prepaid contracts, and dedicated hosts can carry capital characteristics depending on contract structure and your accounting policies. The larger the commitment, the less “pay as you go” describes what is happening.

The pattern that played out with cloud over the past decade is now repeating with AI, at higher speed. Cloud moved infrastructure from owned to rented over years; token-based AI services arrived as pure consumption from day one, with adoption cycles measured in weeks.

The shift to operating spend also changed the control problem. A data center purchase gets scrutinized once, up front. Cloud consumption accrues continuously across hundreds of services and thousands of decisions, which is why continuous cost anomaly detection replaced the annual procurement review as the real control point.

Is AI spend CapEx or OpEx?

It depends entirely on how you consume the compute. Buying GPU clusters or building on-premises training infrastructure is capital spending. Consuming AI through per-token APIs from providers like OpenAI or Anthropic is operating spending. Reserved AI capacity and long-term compute contracts sit in the gray zone between them.

Training and inference often land on opposite sides of the line, too. A company that trains models on owned hardware capitalizes the infrastructure, while its inference bill, the per-request spend of serving users, runs through operating expenses. Teams that track inference spending closely often discover it dwarfs what the original business case modeled.

Alphabet’s filings show what the capital side looks like at the extreme. Depreciation of property and equipment ran $7.1 billion in Q2 2026, up 42% from $5.0 billion a year earlier: yesterday’s capital spending arriving on today’s income statement. Net property and equipment grew from $246.6 billion to $321.2 billion in the six months to June 30, 2026, and long-term debt roughly doubled, from $46.5 billion to $98.2 billion, helping fund the buildout.

“Our AI investments are redefining what’s possible across every part of our business,” Alphabet CEO Sundar Pichai said in the company’s Q2 2026 earnings release. Alphabet CFO Anat Ashkenazi told analysts on the earnings call that “free cash flow will remain under pressure” as infrastructure investment continues.

One company’s capital spending becomes its customers’ operating spending. Google Cloud revenue grew 82% to $24.8 billion in the same quarter, with segment operating income rising from $2.8 billion to $8.8 billion, and as of July 2026, Gemini models process 22 billion API tokens per minute. Every one of those tokens is operating spend on a customer’s books, funded by capital spend on Alphabet’s.

For those customers, the classification question quickly becomes a margin question. API consumption that powers a product feature belongs in COGS, where it compresses gross margin directly. Getting the split right requires knowing your cost per customer and per feature, and it shapes everything from AI pricing models to how your SaaS unit economics read in a board deck.

When can you capitalize software and AI development costs?

Under ASC 350-40, the accounting standard for internal-use software, capitalization depends on the project stage. Costs in the preliminary stage are expensed. Costs in the application development stage, including compensation for employees directly building the software, are capitalized. Post-implementation and maintenance costs are expensed again. ASU 2018-15 extends similar treatment to implementation costs in cloud computing arrangements.

AI development strains these categories. Is a large training run application development or research? Is fine-tuning an existing model an improvement that extends useful life, or a recurring operating activity? The standards predate frontier-scale model development, and treatment varies by arrangement, so this is a conversation to have with your accounting team early rather than at audit time.

The stakes of getting depreciation right are easy to underestimate. A nonresidential building purchased for $800,000 depreciates over 39 years, roughly $20,513 per year in deductions. Companies choose straight-line depreciation to spread the deduction evenly, or accelerated methods like double-declining balance when the asset loses value quickly.

GPU hardware makes the useful-life assumption unusually consequential. Assign a GPU cluster a six-year life and each dollar of capital spending produces a small annual depreciation charge. Assign it three years and the charge doubles, cutting reported operating income for the same underlying asset.

With Alphabet alone guiding to $195 to $205 billion of capital spending in 2026, small differences in that single assumption now move billions across income statements. The assumption itself is a judgment call about how fast the hardware becomes obsolete, which makes it a recurring audit conversation rather than a one-time setting.

How do finance teams decide between CapEx and OpEx?

The decision rests on four factors: cash position, flexibility requirements, tax strategy, and whether you can actually measure the spend you’re classifying. The first three are well covered in accounting guidance. The fourth is where most AI-era classification efforts quietly fail.

Cash position sets the ceiling. Companies with strong reserves can afford to buy assets and capture long-run savings; companies protecting runway favor the operating model even when it costs more over time. Flexibility follows the same logic: fast-changing workloads argue for consumption, stable and predictable ones argue for ownership or committed capacity.

Tax strategy pushes in both directions at once. Immediate deductibility makes operating spend attractive in profitable years, while depreciation schedules let capital spend smooth taxable income across periods. The right answer depends on your margin profile and jurisdiction, which is why this call belongs to finance rather than to the team buying the compute.

Then comes the factor the guidance skips. You cannot classify what you cannot see. Deciding whether an AI feature’s compute belongs in COGS requires knowing which workloads, tokens, and infrastructure that feature consumes. Most organizations write the classification policy first and discover afterward that they can’t measure compliance with it.

This is the problem CloudZero addresses.

CloudZero AI Hub brings spend from AI APIs, GPU infrastructure, and cloud providers into one place, and the platform allocates it to the customers, features, and teams driving it, including spend that tagging alone never reaches.

Finance teams use that allocation to separate COGS from operating expenses accurately, feed budgeting and forecasting with real consumption data, and put defensible numbers in front of the board.

Companies measuring cost-to-serve this way range from fintech and cybersecurity to marketplaces and developer platforms. For the board conversation itself, the AI ROI board slides guide covers how to present AI spend to directors and investors.

If AI spend is starting to blur your P&L lines, schedule a demo, get a free cloud cost assessment, or take the self-guided tour to see your options.

Frequently asked questions about CapEx and OpEx