Sub topic 7
Compute vs EC2 Instance Savings Plans
This chapter assumes you know what an EC2 instance family and a Region are, and that you know the basic idea of a spend commitment from the earlier chapter on Savings Plans. It covers the two Savings Plans types you use for EC2, what each one applies to, how AWS matches usage to a plan, and how to choose between them.
Two plans, one commitment model
Both plan types work the same way. You commit to spend a fixed amount per hour, for example $1.00/hour, for a one-year or three-year term. In return, usage that the plan covers is billed at a discounted Savings Plans rate. Whatever the plan does not cover is billed at On-Demand rates.
The two types differ in how much they restrict what can earn the discounted rate. A narrower plan gives a bigger discount.
| Property | Compute Savings Plans | EC2 Instance Savings Plans |
|---|---|---|
| Maximum discount vs On-Demand | Up to 66% | Up to 72% |
| Instance family | Any | One family you choose, such as M5 |
| Region | Any | One Region you choose, such as us-east-1 |
| Instance size | Any | Any size within the family |
| Operating system | Any | Any |
| Tenancy | Any (except Dedicated Hosts) | Any (except Dedicated Hosts) |
| Also covers Fargate and Lambda | Yes | No |
| Reserves capacity | No | No |
The maximum percentages are upper bounds. The discount you actually get depends on the instance family, Region, term, and payment option.
Compute Savings Plans
A Compute Savings Plan applies to EC2 usage regardless of instance family, size, Region, operating system, or tenancy. It also applies to AWS Fargate and AWS Lambda usage. This breadth gives you three kinds of freedom:
- Modernize instances. You can move from C5 to C7g (a Graviton-based family) and the commitment follows the usage.
- Move between Regions. If you shift a workload from us-east-1 to eu-west-1, the plan still applies.
- Change compute service. If you migrate a workload from EC2 to Fargate, the plan still covers it.
You pay for this flexibility with a lower maximum discount.
EC2 Instance Savings Plans
An EC2 Instance Savings Plan commits you to one instance family in one Region. For example, you might buy "M5 in us-east-1". Inside that boundary the plan is still flexible. It covers m5.large, m5.2xlarge, and m5.12xlarge alike, on Linux or Windows, on shared or dedicated tenancy.
The plan does not follow you out of the family or the Region. If you move from M5 to M6i, the new instances earn no discount from the M5 plan. The M5 plan then goes partly or fully unused, and you pay for the unused commitment anyway.
This is the closest Savings Plans equivalent of a Standard Reserved Instance. It gives the highest discount and the least freedom.
How a plan is applied to your usage
AWS applies Savings Plans automatically, hour by hour, in this order:
- EC2 Instance Savings Plans are applied first, to matching family and Region usage.
- Compute Savings Plans are applied next, to remaining eligible usage.
- Within a type, AWS applies the plan to the usage that yields the highest discount first.
- Eligible usage beyond the commitment is billed at On-Demand rates.
Savings Plans do not apply to Spot Instances, and they do not apply to Dedicated Hosts. Spot has its own pricing, covered in a later chapter.
A worked hour-by-hour example
The rates below are illustrative, not real prices. Suppose you hold an EC2 Instance Savings Plan with a $1.00/hour commitment. Assume the plan rate for an m5.large is $0.05/hour and the On-Demand rate is $0.096/hour. The commitment can therefore pay for 20 m5.large instance-hours in each hour.
- Hour 1: 15 instances running. Usage costs 15 × $0.05 = $0.75 at the plan rate. You still pay the full $1.00 commitment, so $0.25 goes unused. Utilization is 75%.
- Hour 2: 20 instances running. The commitment is fully used. The cost is $1.00, and utilization is 100%.
- Hour 3: 25 instances running. 20 instances use the commitment ($1.00). The other 5 are billed at On-Demand: 5 × $0.096 = $0.48. The total is $1.48.
Two lessons follow. First, an unused commitment is lost, because it does not roll over to the next hour. Second, over-committing is costly. Under-committing only means some usage stays at On-Demand rates.
Payment options and terms
Both types offer the same choices, covered in more detail in the Reserved Instances chapters:
- Term: one year or three years.
- Payment option: All Upfront, Partial Upfront, or No Upfront.
All Upfront gives the best discount, and No Upfront gives the most cash-flow flexibility. In every case the total commitment is still defined as an hourly amount.
Choosing between the two types
Ask three questions about the workload you want to cover.
- Will it stay in one instance family and one Region for the whole term? If yes, the EC2 Instance plan's higher discount is available. If you are unsure, the Compute plan is safer.
- Does it use Fargate or Lambda, or might it? Only Compute Savings Plans cover them.
- Is a modernization planned? Moving to a newer generation or to Graviton during the term strands an EC2 Instance plan's commitment.
A common pattern is a Compute plan for the broad, changing base of your usage. Add EC2 Instance plans only for stable, well-understood families, such as a database fleet on a fixed family that you do not plan to move.
Savings Plans do not reserve capacity
A Savings Plan is purely a billing discount. It does not guarantee that an instance is available when you launch it. A zonal Reserved Instance can reserve capacity in an Availability Zone, but Savings Plans cannot. If you need guaranteed capacity, pair your plan with an On-Demand Capacity Reservation. The plan then discounts the reserved instances' usage, and the reservation guarantees they can launch.
Getting a recommendation for each type
Cost Explorer can estimate a commitment for you. This command asks for a Compute Savings Plan based on the last 30 days of usage, for a one-year, no-upfront term.
aws ce get-savings-plans-purchase-recommendation \
--savings-plans-type COMPUTE_SP \
--term-in-years ONE_YEAR \
--payment-option NO_UPFRONT \
--lookback-period-in-days THIRTY_DAYSTo compare, change only the type. An EC2 Instance recommendation is split by family and Region, so you may get several entries instead of one. The --query option below trims the output to the fields you compare.
aws ce get-savings-plans-purchase-recommendation \
--savings-plans-type EC2_INSTANCE_SP \
--term-in-years ONE_YEAR \
--payment-option NO_UPFRONT \
--lookback-period-in-days THIRTY_DAYS \
--query 'SavingsPlansPurchaseRecommendation.SavingsPlansPurchaseRecommendationDetails[].{Family:SavingsPlansDetails.InstanceFamily,Region:SavingsPlansDetails.Region,HourlyCommitment:HourlyCommitmentToPurchase,SavingsPct:EstimatedSavingsPercentage}'Read the output with these checks:
- The recommendation is based on past usage. It cannot know about a migration you plan next quarter.
- Compare
HourlyCommitmentagainst your lowest steady hourly usage, not your average. Commitments sized to the average leave unused spend in quiet hours. - A recommendation for one type does not account for plans you plan to buy of the other type. Buy one, wait for the usage data to update, then request recommendations again.
Common mistakes
- Buying an EC2 Instance plan for a family you are about to leave. Check the roadmap first.
- Sizing the commitment to peak usage. Peak hours are rare. The commitment is billed every hour.
- Expecting capacity. Savings Plans never guarantee that an instance can launch.
- Expecting coverage of Spot. Spot Instances are priced separately, so plans do not apply to them.
- Ignoring the order of application. An EC2 Instance plan takes its matching usage before a Compute plan. The Compute plan only sees what is left, so check its utilization after buying an EC2 Instance plan.
Exercise
Your team runs a steady fleet of c5 instances in us-east-1, and plans to move some of it to Graviton (c7g) in eight months. A part of the workload is moving to Fargate. You want one plan for the one-year term. Which type fits best, and why?
Show answer
A Compute Savings Plan. An EC2 Instance plan for c5 in us-east-1 would stop covering the instances once they move to c7g, leaving unused commitment. Compute plans also cover Fargate, so the commitment follows the workload across both changes. You give up some of the maximum discount, but you avoid paying for an unused commitment for the rest of the term.
Exercise
You hold an EC2 Instance Savings Plan with a $2.00/hour commitment. In one hour your covered usage would cost $1.50 at plan rates, plus other eligible usage that would cost $0.80 at plan rates. What do you pay for the covered usage, and how much is unused?
Show answer
You pay $2.00 for the plan-covered portion: the first $2.00 of usage at plan rates uses the full commitment. The remaining $0.30 of usage at plan rates is not covered by the plan, so it is billed at the matching On-Demand rate, which is higher than $0.30. Nothing is unused, because usage exceeded the commitment ($2.30 > $2.00).