Home / Dev & AI / Cloud Cost / AWS Lambda Cost Calculator

Cloud Cost

AWS Lambda Cost Calculator

Estimate your Lambda bill. Enter invocations, average duration and memory, and see request and compute costs with the free tier applied and a growth projection.

Estimated monthly cost

$0

Request cost
Compute cost (GB-seconds)
GB-seconds used
Cost per 1M invocations
Annual estimate

Requests vs compute

Short, light functions are request-bound, long or memory-heavy ones flip to compute-bound.

Cost as invocations grow

Projected monthly spend at 2x, 5x and 10x volume.

What the AWS Lambda Cost Calculator does

AWS Lambda runs your code without managing servers, and it bills on two axes: the number of invocations, and compute measured in GB-seconds, which is memory allocated multiplied by run time. A generous free tier covers the first million requests and 400,000 GB-seconds each month, so low traffic functions can be nearly free.

This Lambda cost calculator computes GB-seconds from your duration and memory, applies the request and compute rates, subtracts the free tier, and shows whether your function is request bound or compute bound. Higher memory speeds execution but raises GB-seconds, so tuning memory is a real optimisation lever.

Heads up on pricing. The rates built into this tool are public list estimates for July 2026 and can change without notice. Providers also offer batch discounts, prompt caching and volume tiers that lower real costs, so treat the output as a planning estimate, not a quote.

The formula

GB-seconds = invocations × (duration ÷ 1000) × (memory ÷ 1024)
cost = (billable invocations ÷ 1M × $0.20) + (billable GB-seconds × $0.0000166667)

Worked example

For 10,000,000 invocations at 200 ms and 512 MB, GB-seconds is 10,000,000 × 0.2 × 0.5 = 1,000,000. After the free tier, requests cost 9 × $0.20 = $1.80 and compute is 600,000 × $0.0000166667 = $10, for about $11.80 a month.

Ways to lower your cloud costs

Frequently asked questions

How is AWS Lambda priced?

By invocations at $0.20 per million and compute at about $0.0000166667 per GB-second, where GB-seconds is memory times duration. The first 1M requests and 400,000 GB-seconds each month are free.

What is a GB-second?

One gigabyte of memory allocated for one second. A 512 MB function running two seconds uses one GB-second. It is the core unit of Lambda compute billing.

Does more memory cost more?

Per second, yes, but more memory also means more CPU, so functions often finish faster. Sometimes higher memory lowers total cost by cutting duration.

When is Lambda cheaper than EC2?

For spiky, low or unpredictable traffic, since you pay nothing when idle. For steady high volume, always-on EC2 or containers can be cheaper per request.

Are these rates current?

They are July 2026 estimates for x86. Arm (Graviton) Lambda is cheaper. Confirm current rates for your region on the AWS pricing page.

Related calculators