AWS Data Transfer Pricing: How to Reduce Your Costs?
In this article, you will learn:
- What are AWS data transfer costs?
- AWS Data transfer pricing and costs division
- How to reduce AWS data transfer costs
- How to optimize Amazon CloudFront CDN costs
AWS (Amazon Web Services) and public clouds are generally based on the premise that cloud-based infrastructure will be more cost effective than operating your own local IT. But customers often open their monthly AWS Cloud bills, hoping to save money, only to find that unexpected AWS data transfer costs seem to have appeared from nowhere. Where do these AWS data transfer costs come from, and what measures can you take to reduce them?
This blog post introduces the different types of data transfers that may occur on AWS bills, AWS inbound and outbound data transfer pricing and some AWS cost optimization techniques to control the cost of these data transfers.
What are AWS data transfer costs?
AWS data transfer costs are charges AWS applies to transferring data between AWS and the public Internet or between AWS services like Amazon EC2 instances and S3 buckets.
At first, it’s good to understand that for many AWS services, data transfers are divided into:
- Data transfer in (DTI): Also called AWS inbound data transfer. These are uploads into the service, for instance, if you upload new objects into S3 buckets or download files onto your Amazon EC2 instances. Data basically flows into these AWS services. This type of data transfer is usually free.
- Data transfer out (DTO): Sometimes called AWS outbound data transfer. One instance of DTO would be if you download something from your S3 bucket into your local hard drive. In many cases, outbound transfers incur charges.
On your AWS bill, you can also find data transfer and bandwidth charges. Data transfers are within AWS while bandwidth charges are transfers with the public Internet.
Data transfer and bandwidth are measured in GB per month, and you also pay in terms of GBs used too. Some AWS services offer a free tier, for instance, EC2 instances have 100GB and Amazon CloudFront have 1TB per month of DTO.
A couple of general points about AWS Data Transfer pricing:
- AWS data transfer costs differ based on whether your data is going outside the AWS Cloud to the public Internet or staying inside the AWS infrastructure.
- AWS data transfer costs fluctuate depending on the AWS region.
- Each AWS region has a data transfer fee within and outside of it.
- Data transfers between two regions cost more than within one region.
- Data transfers from one Availability Zone (AZ) to another are costlier than transfers within an AZ.
- Data transfer fees are mostly unidirectional i.e. only data that is going out of an AWS service is subject to data transfer fees.
Here is an AWS data transfer costs diagram with the simplest possible look at what data transfer charges can occur on your AWS bill, using data transfer prices for Europe's central region as an example.
AWS Data transfer pricing and costs division
The best way to understand AWS data transfer costs is by going through them from the following perspectives:
1. Data transfer between AWS and the public Internet
3. Data transfer between AWS and on-premises infrastructure
1. Data transfer charges between AWS and the Internet
These charges may also be called AWS bandwidth pricing as on your AWS bill these are under your region and bandwidth section.
These charges cover all data that has to flow in or out via the public Internet, for instance, pictures that your customer downloads from S3 buckets when he opens your website.
Data transfers from the Internet into AWS are typically free. Data transfer costs from AWS to the public Internet are dependent on the region that you use.
For example, for S3 buckets located in the EU region, the first 100 GB/month is free and the next 9.999 TB/month costs $0.09 per GB. However, if the S3 buckets are located in the Africa (Cape Town) region, the first 100 GB/month is still free, but the next 9.999 TB/month costs $0.154 per GB. You can optimize these costs by using Amazon CloudFront CDN, about which you can read more below.
StormIT offers custom CloudFront pay-as-you-go pricing and you pay only for what you use. There is no minimum fee and you can start as low as 1TB/month.Estimate savings
2. Data transfer within AWS
Within AWS, you can transfer data across regions or within a region.
Data transfer across regions
Transferring data between AWS services across regions has the same cost structure as transferring data between AWS and the Internet.
These costs also depend on the region, although the price starts much lower: in Europe, it costs $0.02 per GB while in the main regions of the USA, it costs $0.01 per GB to send data from an EC2 instance to another in a second region. Data transfer into an AWS region from any other AWS region is free.
Data transfer within regions
The cost of transferring data between AWS services within a region depends on whether you’re transferring data within or across AZs.
- Data transfers are free if you are within the same region, within the same availability zone, and use a private IP address.
- Data transfers within the same region, but in different availability zones, have a cost associated with them.
Here is a summary table showing the most used AWS services and if they are charged for multiple types of DTO and DTI.
3. Data transfer between AWS and on-premises infrastructure
This type of data transfer will occur when your AWS service needs to access infrastructure in your on-premises environment. If you communicate directly with AWS services and your on-premises infrastructure via the public Internet, the charges are the same as for data transfer between AWS and the Internet. So if you send any data into AWS infrastructure, it will be free, and if you send anything out from AWS to your on-premises servers, DTO charges will apply ($0.09 per GB for the Europe regions from S3).
If you don’t communicate with AWS directly over the Internet, you can use two common AWS services: Site-to-Site VPN and AWS Direct Connect.
AWS Direct Connect can be a very useful way to send data from the AWS environment to your on-premises servers because the rate for DTO in US and Europe regions starts around $0.02 per GB. However, AWS Direct Connect does mean you need to add the costs of the port, etc.
Want to know more about AWS data transfer? Try watching our video below:
Still, having problems with understanding your AWS data transfer costs? Contact us, and our certified AWS architects will help you find your solution.Contact us
How to reduce AWS data transfer costs
AWS data transfer pricing general tips
Below are a few things to remember about data transfer costs. A couple of these points are described in more detail in later sections:
- Avoid routing traffic over the Internet when connecting to AWS services from within AWS by using VPC endpoints:
- VPC gateway endpoints allow communication to Amazon S3 and Amazon DynamoDB without incurring data transfer charges within the same region.
- VPC interface endpoints are available for some AWS services, but this type of endpoint incurs hourly service charges and data transfer charges.
- Use AWS Direct Connect instead of the Internet for sending data to on-premises networks, when it makes sense.
- Consider Amazon CloudFront CDN. Data transferred out to the Internet is going to be less expensive from CloudFront than if transferred out from AWS regions and with less latency. If you have a public-facing service that delivers rich content such as videos or audio files, this might be a particularly good option. Read more in the sections below.
Regions and AZs
Traffic that crosses a regional boundary will typically incur a data transfer charge. Avoid cross-region data transfer unless your case requires it.
Traffic that crosses an AZ boundary typically incurs a data transfer charge. Use resources from the local AZ whenever possible.
Regions and AZs
Leverage the AWS Free Tier. Under certain circumstances, you may be able to use your workload free of charge.
AWS data transfer pricing specific tips
1. Architect AWS environment to optimize data transfers
Reduce your data transfer costs by designing an infrastructure where data flows along the least expensive routes.
a. Choose the right AWS Region
Sometimes it’s possible to choose the region in which your architecture should reside. The decision should be also dependent on the region's egress costs.
For example, the price of data transfer out of the São Paulo (South America) region to all other regions is $0.14 per GB, and transfers from the Singapore region to all other regions cost $0.09, whereas the transfer cost from the Ohio region is only $0.01. Remember that these rates vary considerably and if your use case allows it, use the cheapest region possible.
The table below shows the AWS data transfer out pricing of a few of the most used regions to all other AWS regions.
The same thing is also applicable to data transfers between AWS and the Internet. The table below shows the pricing of DTO of Amazon S3 for the first 10TB from a few of the most used regions to the Internet.
b. Keep your data within the same region or AZ
Yes, sometimes you must keep your data in two separate AZs just in case, so your infrastructure fits your RPO and RTO. And if you are trying to protect against a natural disaster that may affect a whole region, then you would want to use two regions. Always consider that data transfer costs can vary widely by AWS region. Regions in the US and Europe are generally the cheapest, while Singapore, India, and South America are the most expensive.
Sometimes mistakes happen and someone from your team creates EC2 instances or AWS lambda functions in different AZs, forgetting about the charges that will apply if these communicate with the database or any other AWS services in a different AZ.
c. Optimize the usage of Public IP addresses
Data transfer costs are higher with Public IP or Elastic IP addresses than with a Private IP address. Consistently using private IP addresses can drastically reduce costs. You can optimize your spending by using a private IP address when transferring data that doesn’t leave your region or AZ. The rules about IP addresses are best explained in the Data Transfer section of the AWS page dedicated to explaining EC2 pricing.
2. Use and optimize Amazon CloudFront CDN
Without CloudFront, your architecture would normally incur standard charges for DTO from AWS services to your clients over the Internet as seen in the diagram below.
Using a content delivery network such as Amazon CloudFront is essential to keeping data transfer costs low. CloudFront moves your most accessed content to the “front” of the AWS network (i.e., PoPs), ensuring fast delivery to your end-users. Data transfers into CloudFront from other AWS resources (S3, EC2, API Gateway) are free.
By caching your content in CloudFront, you can greatly reduce the charges incurred. CloudFront offers a free tier that entitles customers to 1 TB outbound data transfer and 10 million HTTP requests per month. Data transfer out from CloudFront to the Internet is typically cheaper than standard data transfer rates. You can learn more about CloudFront pricing in our article.
At StormIT we have helped many customers to optimize their overall spend on data transfer (egress bandwidth) from different industries with a broad range of use cases from web applications and blogs to media streaming and gaming. Obviously, every project/case is unique, but we are confident that by smartly using CloudFront it is possible to achieve overall lower costs and improved performance.
3. Experiment with the AWS calculator
AWS calculator allows you to experiment with different configurations to see how you can save the most money. It's also a great way to instantly see which variables are affecting your costs. Try some more values to get an idea of your costs.
As your workload on AWS Cloud increases, it’s difficult to control data transfer charges and AWS bandwidth costs between services and your users. AWS provides the ability to deploy across multiple Availability Zones and regions. With just a few clicks, you can create distributed infrastructure. This blog post should provide information to help you make informed decisions.