EC2 Instance Rightsizing
CostLens surfaces AWS Cost Explorer rightsizing recommendations to downsize over-provisioned EC2 instances.
CostLens surfaces EC2 rightsizing recommendations directly from AWS Cost Explorer. These identify instances that are consistently over-provisioned — running on a larger instance type than your actual workload requires — so you can reduce costs without impacting performance.
Changing instance type requires a stop/start
Modifying an EC2 instance type requires the instance to be stopped and restarted. This causes a brief interruption. Schedule this fix during a maintenance window and confirm your application restarts cleanly before applying.
How it works
AWS Cost Explorer analyses usage
CostLens queries the AWS Cost Explorer Rightsizing Recommendations API, which analyses 14 days of actual CPU, memory, and network utilisation for each running instance.
Recommendations are imported
Only recommendations of type Modify (downsize) with a positive estimated saving are imported. Recommendations to terminate instances are excluded.
Severity and savings are assigned
Severity is based on the estimated monthly savings returned directly from Cost Explorer's own calculation.
Explanation is generated
Aevi generates a plain-English explanation of why the instance is over-provisioned and what the recommended change will do.
What to do
- Review the recommendation detail — note the current instance type, the recommended type, and the performance risk score.
- If performance risk is low, the change is safe for most workloads. A higher risk means more caution is warranted.
- Apply the fix in CostLens — the instance will be stopped, its type changed, and it will be restarted.
- Monitor your application for 24–48 hours after the change.
Tip: test in non-production first
If the same instance type runs in a non-production environment, apply the change there first to confirm no performance degradation before touching production.
Severity levels
| Severity | Estimated monthly savings |
|---|---|
| critical | >$500 |
| high | $100–$500 |
| medium | $20–$100 |
| low | <$20 |
Required IAM permissions
Included in the standard CostLens IAM policies from AWS Accounts:
ce:GetRightsizingRecommendation
ec2:ModifyInstanceAttribute
ec2:StopInstances
ec2:StartInstances
Limitations
- Recommendations are based on the previous 14 days of usage. Instances with variable or seasonal workloads may show false positives.
- AWS Cost Explorer must be enabled in the account. If it has been recently activated, it requires at least 14 days of data before recommendations appear.
- Results are cached for 7 days to minimise Cost Explorer API costs.