Local vs Cloud LLM Break-Even Calculator
Calculate whether a local LLM or a cloud API costs less per 1M tokens, including amortized hardware, power, and the break-even point.
The API is cheaper: $2.20 per 1M tokens against $5.23 running locally. Local breaks down as $1.06 power plus $4.17 amortized hardware, at 33 tokens per second. The hardware pays for itself in about 88 months at this volume, after which local usage saves money every month against the API.
Overview
Running an LLM locally costs less than an API only above a volume threshold. Power cost per 1 million tokens is hours to generate them (1,000,000 divided by tokens per second divided by 3600) times kilowatts times your electricity price. Add hardware cost amortized over its payoff period and daily token volume, then compare the total against blended API pricing to find your break-even point.
How it works
- 1Enter how many tokens you generate per day.
- 2Enter your local hardware's cost and how many months you want to amortize it over.
- 3Enter its power draw in watts, your electricity price per kWh, and its tokens per second.
- 4Enter the cloud API's price per 1M input and output tokens, or pick a preset, and set what share of your tokens are output.
- 5Read the live verdict: which option is cheaper per 1M tokens right now, and how many months until the hardware pays for itself.
- 6Copy the plain-text summary to share or save.
Worked example
A $3,000 rig at moderate volume: the API wins
At 1,000,000 tokens a day on a dual-3090-style rig (33 tokens per second, 700 watts, $0.18 per kWh electricity), with a $3,000 hardware cost amortized over 24 months, power costs $1.06 and hardware $4.17 per 1M tokens, for a local total of $5.23. Claude Haiku 4.5 pricing ($1 input, $5 output, 30 percent output share) blends to $2.20 per 1M tokens, so the API is cheaper here, and the hardware would take about 88 months to pay for itself against that API price, longer than most people keep the same rig.
10 million tokens a day: local wins, and pays back fast
Same rig, same power price, but 10,000,000 tokens a day instead of 1,000,000. The hardware cost per 1M tokens drops to $0.42 (the same $3,000 spread over a much bigger monthly token volume), for a local total of $1.48 per 1M tokens. Against Claude Sonnet 4.6 pricing ($3 input, $15 output, 50 percent output share, blending to $9 per 1M tokens), local is now the clear winner, and the same $3,000 rig pays for itself in about 1 month of running at that volume.
Methodology & privacy
Power cost per 1M tokens is the hours needed to generate 1M tokens (1,000,000 divided by tokens per second, divided by 3600 seconds per hour) times the hardware's power draw in kilowatts, times your electricity price per kWh. Hardware cost per 1M tokens straight-line amortizes the hardware's purchase price over the number of months you choose, then spreads that monthly figure across the tokens you actually produce in a month (daily token volume times 30). Local cost per 1M tokens is power plus amortized hardware, added together. The API's price per 1M tokens blends its input and output rates by your output share (the fraction of tokens that are generated output rather than input or prompt tokens). The break-even point answers a different question: will the hardware ever pay for itself. It nets the API price against ONLY the local variable cost, electricity, since the hardware purchase is the cost being recovered, not a recurring cost that recovers it; if electricity cost alone already meets or exceeds the API price, no volume of usage ever pays the hardware back, and the calculator reports that instead of a number. This is a linear amortization model, not a depreciation schedule: it does not model resale value, hardware failure, or the possibility of upgrading before the amortization window ends. It also excludes your own time spent maintaining, updating, and troubleshooting a local setup, real but hard to price consistently, and it excludes idle power draw between requests and prompt-processing time, counting only the generation throughput you enter. API prices are inputs you can and should edit; they change often and the ones shown as presets are the defaults verified on the date above, not a live feed.
- Source: r/LocalLLaMA: "Is anyone actually using local models to code..." (hand-derived kWh-to-dollars math this tool automates)
- Source: r/LocalLLaMA: "Does anyone have a price comparison breakdown of..." local vs cloud GPU vs API
- Source: r/LocalLLM: "LocalLLM dilemma" (paid API cheaper at low volume, local cheaper at high volume)
- Source: r/LocalLLaMA: hardware vs Mistral API break-even question
- Source: OpenAI API pricing (GPT-5.4 mini price used as a preset, verified 2026-07-06)
- Source: Anthropic Claude API pricing (Haiku 4.5 and Sonnet price presets, verified 2026-07-06)
Every number you type into this calculator, hardware cost, electricity price, API prices, and token volume, stays in your browser. There is no upload, no account, and no server call; results recompute live as you type, and nothing is saved unless you copy the summary yourself.
FAQ
Is running an LLM locally cheaper than OpenAI?
+
It depends entirely on your token volume. At low daily volume, a cloud API is almost always cheaper because you avoid the hardware cost entirely. Above a volume threshold that depends on your hardware cost, power price, and the API's price, local usage becomes cheaper because you are no longer paying a per-token markup. Enter your own numbers above to see which side of that threshold you are on.
How much does electricity cost to run a local LLM?
+
Power cost per 1M tokens is the hours needed to generate them (1,000,000 divided by tokens per second, divided by 3600) times your hardware's watts divided by 1000, times your electricity price per kWh. At 33 tokens per second, 700 watts, and $0.18 per kWh, a widely cited r/LocalLLaMA hand calculation, that works out to about $1.06 per 1M tokens.
What is the break-even point for local LLM hardware versus an API?
+
It is the number of months of avoided API spend it takes to cover your hardware's purchase price, counting only electricity as the ongoing local cost, since the hardware cost is what is being recovered. If your electricity cost per 1M tokens is already at or above the API's price, there is no break-even; no amount of usage pays the hardware back.
How do I compare local LLM cost per 1M tokens to API pricing?
+
Add your power cost per 1M tokens to your hardware cost amortized over its payoff period and your daily token volume; that is your local cost per 1M tokens. Blend the API's input and output prices by the share of your tokens that are output. Whichever total is lower is cheaper for you right now, at your current volume.
Does this calculator include the cost of my time maintaining a local rig?
+
No. It only counts hardware capex and electricity, the costs that show up on a receipt. Setting up, updating, and troubleshooting a local model server takes real time that this calculator does not price, and that time cost is worth weighing separately alongside the dollar totals shown here.
Do the API prices in this calculator update automatically?
+
No. Every API price field is a plain number you can edit, seeded with defaults verified on the date shown, because provider prices change often and a stale hardcoded price would quietly mislead you. Check the current price on the provider's own pricing page and type it in before trusting the result for a real purchase decision.
Related tools
Can Your Mac Run It? LLM RAM Calculator
Check whether a model and quant will fit your Mac unified memory or GPU VRAM, with KV cache math, a max context solver, and a tokens per second estimate.
GGUF Quant Decoder: What Does Q4_K_M Mean?
Type any GGUF quant name, like Q4_K_M or IQ4_XS, for a plain-English decode, plus a picker for which quant fits your memory.
Token Counter & Context-Window Fit (with boundary view)
Paste text for an exact GPT-4o/GPT-4 token count, rough Claude, Llama 3, and Gemma estimates, and a colored boundary view. Nothing you type leaves your browser.
Is It Worth Automating? ROI Calculator
Find out if automating a task is worth the build time. Enter your frequency, savings, and build hours for a break-even point and a clear verdict.
This tool fixes one moment. recal handles the whole day.
recal is a private brain for your Mac. It watches how you work, on device, and starts doing your busywork itself. You approve every action.
Get early access