Compute Cost Calculator
How much will your GPU or CPU compute workload cost?
Find out whether your AI project fits your compute budget. Enter GPU/CPU type, usage hours, and cloud provider rates — see total compute costs, cost per hour, and monthly projections. Assumes continuous usage at listed provider rates.
—
Send feedback
💡 Share your idea or report a problem
✓ Thanks! We'll take a look.
Learn more
How It Works
The formula, explained simply
A single training run can cost more than a luxury car, while inference might cost pennies per request. The difference lies in time and parallelization — training a large model might require 1000 GPU-hours, while serving that model to users needs just milliseconds per query. Cloud providers charge by the hour for compute resources, regardless of whether you're using 10% or 100% of the hardware capacity.
This calculator assumes you're paying standard on-demand cloud rates. Most major workloads use spot instances (60-90% cheaper) or reserved capacity (30-70% cheaper) instead. The hardware type determines both speed and cost — an H100 GPU costs 4x more per hour than a T4 but trains models 10x faster, making it cheaper for training but expensive for light inference work.
The number of instances multiplies both cost and speed linearly. Running 8 GPUs costs 8x more but often finishes training in roughly 1/8th the time, keeping total costs similar while dramatically reducing time-to-results. This parallel scaling breaks down at high instance counts due to communication overhead between machines.
When To Use This
Right tool, right situation
Use this calculator when planning AI projects, comparing cloud providers, or setting research budgets. It's essential for grant applications requiring cost estimates and for startups projecting infrastructure spending as they scale.
For training large models, calculate costs across multiple scenarios — single large instance versus distributed smaller instances. Factor in your time cost too — a $500 training run that finishes overnight might be cheaper than a $200 run that takes a week when you account for iteration speed.
For inference services, estimate based on expected traffic rather than peak capacity. A model serving 1000 requests per hour needs very different infrastructure than one handling 1000 requests per second. Use autoscaling to match compute costs to actual demand rather than provisioning for worst-case scenarios.
Common Mistakes
Why results sometimes look wrong
The biggest mistake is forgetting to shut down resources after experimentation. A single H100 left running for a month costs $2,400 at standard rates. Set up billing alerts and automatic shutdowns to prevent runaway charges.
Underestimating data transfer costs catches many first-time users. Moving large datasets between regions or downloading results can cost more than the actual compute time. Keep data and compute in the same region and use object storage for long-term datasets.
Choosing the wrong instance type wastes money in both directions. Oversized instances idle expensive resources, while undersized instances take longer to complete tasks. A training job that needs 40GB RAM won't work on a 32GB instance, forcing you to the next tier up regardless of CPU or GPU utilization.
The Math
Worked examples and deeper derivation
The basic formula is straightforward: Total Cost = Hourly Rate × Usage Hours × Number of Instances. A $2.50/hour A100 used for 24 hours costs $60. Add three more instances and the cost becomes $240, but training might finish in 6-8 hours instead of 24.
Real pricing complexity comes from discounts and utilization. Spot instances can drop an $8/hour H100 to $2/hour, but AWS can reclaim the instance with 2 minutes notice. Reserved instances require 1-3 year commitments but guarantee availability. Sustained use discounts apply automatically after running instances for 25% of the month.
Memory and storage add separate costs often overlooked in initial estimates. A 100GB dataset costs $2-5/month in object storage but $50-100/month in high-performance storage attached to compute instances. Network egress charges apply when moving data between regions — downloading 1TB costs $90 from AWS, potentially more than the compute time itself.
Expert Unlock
The thing most explanations skip
Cloud pricing listed as 'per hour' actually bills by the second after the first minute, but launching overhead means jobs under 5-10 minutes often cost the same as longer runs. Practitioners use container orchestration to batch small jobs and amortize startup costs across multiple tasks. Multi-region training can violate data residency laws even when technically cheaper.
Why do cloud compute costs vary so much between providers?
Need something this doesn't cover?
Suggest a tool — we'll build it →