AWS costs can be a nightmare to understand, let alone optimize. Whether you’re despairing at your Cost and Usage Reports or losing your mind at the thousands of combinations of discounts, EC2 instances, and pricing plans, we know the pain you’re going through.
This post will solve all of those problems, worries, and difficulties.
Today we’re going to dive into what some of the most common AWS costs are, the hidden costs that you’re getting caught out by, and how to deal with all of them both natively and through a much less stressful method.
- Common AWS services and their costs
- Hidden AWS costs
- Tips and tricks for reducing AWS costs
- The easiest way to cut AWS costs
Let’s get started.
Note that all prices herein are based on the US East (Ohio) Region of AWS and are accurate at the time of writing (June 19th, 2023).
Common AWS services and their costs
The main issue when trying to calculate or predict your current AWS costs is the sheer breadth of services and hidden charges you can use or incur. AWS is a vast library of tools and services, some of which are entirely free, most of which have a free tier (that also needs to be factored into your bills), and others are entirely paid-access-only.
You need to know exactly which services you’re using and which additional costs you’re piling on before you can start to manage and reduce expenditure. So let’s start from the top. You’ll likely need to cover at least four aspects:
- Content distribution
No matter what purpose your cloud computing operations are serving, you’re probably using some sort of AWS storage solution at the very least. The systems you most likely have in place are EBS (which stores any data needed by an EC2 server) and S3,(which offers access-anywhere file storage) whose pricing we’ve covered in full in their own articles:
To summarize their pricing briefly here though, running a gp3 EBS block costs $0.08 per GB per month and is charged by the seconds of usage (with a minimum charge of 60 seconds). For 3,000 GB being stored for 24 hours in a month it would thus cost you $8.00 (((3,000 x $0.08) x 86,400 seconds) / 2,592,000 seconds). There are extra charges for IOPS and throughput but we’ll tackle those in the “hidden AWS costs” section. Otherwise the only EBS costs left are those related to EBS Snapshots (the AWS term for backup copies), of which the Standard pricing is $0.05 per GB per month. You’ll also only be charged for the amount of data that was added or changed since the last Snapshot.
S3 pricing is a little more complex, but it all boils down to only charging you for what you use. There are different pricing plans depending on how readily you’ll need to access your data (eg, S3 Infrequent Access is cheaper than S3 Standard), but S3 Standard pricing is $0.023 per GB for the first 50 TB per month, $0.022 per GB for the next 450 TB per month, and $0.021 per GB per month for anything over that first 500 TB.
Next you’ll likely need to run some kind of server or server-like instance to handle the computational requirements of your software. You’ll often do this by paying for an EC2 instance, although the EC2 instance type and thus its price will depend on your needs. For now, we’ll keep containers and serverless compute technologies out of the conversation, and say that a t3.small instance fits the bill to keep this simple.
The trouble is that EC2 instances don’t just have one price - it all depends on the pricing plan you decide to use. We’ve covered the pros and cons of each of these EC2 instance pricing plans before, but the basics are that On-Demand is the most expensive but you’re guaranteed a dedicated instance, Savings Plans are up to 72% cheaper than On-Demand but require a commitment of 1-3 years, Reserved Instances are pretty much fully purchase for a specific duration (1-3 years) and the remaining time can be sold on if you don’t want them, and Spot Instances offer heavy discounts but availability can be withdrawn if those instances are in demand. There are one or two other discount plans (eg, ones relying on you using your own hardware or software licenses) but these are the main 4.
Again, let’s keep it simple by saying that you’re paying for the t3.small instance via On-Demand pricing. This will set you back $0.0208 per hour that the instance is running.
For your database you’ll likely be looking towards Amazon RDS, which offers fully managed databases for the majority of database license types. Much like EC2, you have more than one pricing plan to choose from here too. On-Demand pricing is what we’ll use as an example, but it is more expensive than the alternatives, which include reserved instances or even the serverless Aurora version of RDS. Plus, for some read/write heavy workloads, there are alternative Aurora pricing options where you aren’t charged by IOPS. For sanity’s sake, we’re going to assume you’re looking to use RDS with PostgreSQL using just a single db.t3.small instance in a single availability zone.
Amazon RDS On-Demand pricing will set you back $0.0360 per hour that the instance is running, but that’s not counting the cost to store its data, which can be up to 0.125 per GB-month depending on your selection of storage drive.
Finally, we have the content distribution solution. This will, funnily enough, come in the form of AWS’ resident CDN (Content Distribution Network) CloudFront. As with most other AWS-related financial topics, we’ve also written a full post detailing all you need to know about AWS CloudFront pricing, but let’s quickly cover the basics here.
The free tier of CloudFront offers up to 1 TB of data transfer out per month, 10,000,000 HTTP or HTTPS requests per month, 2,000,000 CloudFront Function invocations per month, 1,000 free data invalidations per month, and free SSL certificates. Beyond that, the price of data transferred out depends on the destination it’s being sent to, and how much is being sent. We’ll keep it simple and say that you’re transferring data out to the US, Mexico, Canada, Europe, and/or Israel, as those are the same price and also the cheapest data transfer destinations. You’ll then pay $0.085 per GB for the first 10 TB (beyond the free allowance), scaling down to $0.020 per GB for anything beyond 5 PB. Further HTTP requests in the US are $0.0075 per 10,000, and HTTPS requests are $0.0100 per 10,000.
That should be all of the AWS costs you need to account for when setting up a small application, right? Well, sadly not…
Hidden AWS costs
AWS costs are never simple to calculate, and one of the reasons for this is the number of extra charges that you need to remember beyond the standard product and service pricing.
First off, the best way to know whether you’re going to incur any extra costs will always be to read AWS’ pricing information carefully and to know the limits of the pricing plans you’re on. Whether you’re utilizing a free plan or a paid one that has certain limits (but allows for paid extras beyond those limits), only you will be able to fully grasp the scope of your cloud computing operations.
However, much like how we pointed out some of the common services you’ll be paying for above, there are a few hidden costs that are easy to forget, but are common to incur.
The first is extra charges for IOPS and throughput with both your compute and database data storage. You’re not just paying for storage, after all. Let’s use EBS pricing as an example. The limits to be wary of here are that you’ll get 3,000 IOPS and 125 MB/s throughput for free (for our gp3 example at least). Beyond that you’ll be paying $0.005 per provisioned IOPS per month and $0.040 per provisioned MB/s per month. It’s not much, but if you’re running a large operation then these costs will add up.
Next are data transfer charges, and this is the big one to be wary of. Data transfer is typically charged depending on the origin and destination of the transfer. Sometimes, such as when transferring data within the same AWS Region and from an EC2 instance out to CloudFront, there will be no charge. However, most of the time (especially if you’re transferring data from AWS out to the internet) there will be a per GB charge after a certain free tier allowance.
For example, AWS gives you 100 GB of free data transfer from EC2 out to the internet per month, but charges between $0.09 per GB and $0.05 per GB for anything beyond that, scaling down the more data you transfer out.
The specific data transfer costs themselves are numerous enough to warrant their own post. Luckily, if you want to know more, we’ve written an entire post dedicated to data egress and the associated charges incurred by doing it.
Most other hidden fees can be put down to the same thing; paying for something that you’re no longer using.
Whether it’s an EC2 instance that’s no longer running but still charging you for storage, an elastic IP address charging you because you forgot to shut it down along with the associated instance, or even having to pay the full amount for a Reserved Instance which you no longer use but still have time on the contract for, there’s a good chance that you’ve overlooked at least one aspect of your operations. The trick is to either have an iron grip on what to do when you no longer need one of your AWS products or to notice on your bill when you’re paying for something that isn’t getting used.
Speaking of which, it’s time to cover some of the best ways that you can cut your AWS costs!
Tips and tricks for reducing AWS costs
The best tip for cutting your AWS costs in any operation is to have a solid cloud cost management program. This essentially boils down to having measures in place to identify, monitor, analyze, manage, and reduce your costs.
The easiest way to do this natively in AWS is to use a combination of AWS Cost Explorer and your Cost and Usage Reports (CURs) to get a bird’s eye view of what you’re paying and why you’re being charged that much. If you can identify where your money is being spent and cross-reference that with your usage statistics, you should be able to tell whether you’re incurring costs from things that aren’t being used anymore, or you’re overpaying for a service that you’re simply not using enough to warrant the expenditure.
Basically, you should use your CUR data to perform a usage type analysis.
Speaking of analyzing your usage, AWS CloudWatch is a great tool to use when you’re trying to drill down into your usage statistics. Using it to see, say, when an instance you’re running is consistently at less than 50% utilization lets you know that you can probably stand to reduce the instance’s size, save money, and not miss out on performance.
Another great way to cut AWS costs is to review your services and see whether you can save money by switching to a different pricing plan where possible. EC2 instances are a great example of this!
Let’s say that you’re running an instance that’s expensive but totally necessary for your operations. However, that instance is also one that you don’t always need to be available, as the workload it handles isn’t particularly time-sensitive (such as nodes for containers on ECS or EKS). In this case, Spot Instances would make a great, cheaper alternative to paying On-Demand prices, as you can take advantage of low market demand to get a better rate on the instances you need, but won’t suffer if they’re unavailable.
Grouping all of your accounts under a single AWS Organization can also help to cut AWS costs, as AWS offers many discounts that increase based on the amount of a given service or product you use. By grouping accounts into one bill, you might qualify for some extra discounts that they would never have individually been able to.
Those should be enough cost-cutting tips to get you started, but if you’d like to learn more, check out our post on AWS cost reduction techniques.
The easiest way to cut AWS costs
There is one fatal flaw with attempting to cut your AWS costs natively; you’ll be left searching through unintelligible reports (CURs), jumping between multiple separate dashboards to analyze your figures (Cost Explorer, CloudWatch, AWS Billing console, etc.), and generally being given a massive headache trying to do what should be simple.
That’s not even counting the amount you need to know about the available pricing plans and alternate options by heart in order to optimize your costs!
Enter Aimably. Our AWS Cost Reduction Assessment takes all of your AWS data and draws on our own expertise to give you a prioritized list of actions you can take to immediately and effectively cut your AWS costs without breaking a sweat.
Worried about performance dropping in pursuit of low costs? No need, as all of our recommendations come with a risk assessment that accounts for the purpose of your business, your usage statistics, and the potential value of every operation to your business.