AWS: How to save up to 20% costs on Elastic Block Store (EBS)

AWS: How to save up to 20% costs on Elastic Block Store (EBS)

Migrate your gp2 volumes to gp3 to save up to 20% of the storage costs

A quick recap of what is EBS?

Amazon Elastic Block Store (EBS) is a scalable block storage service provided by Amazon Web Services (AWS) designed for use with Amazon Elastic Compute Cloud (EC2) instances for both transactional and throughput-intensive workloads. EBS offers high availability and durability for block-level storage volumes, enabling users to create persistent storage volumes that can be attached to EC2 instances. EBS volumes are highly customizable in terms of size, performance, and storage type, allowing users to tailor their storage solutions to specific application requirements. With features like snapshotting and encryption, EBS provides reliable and secure storage solutions for a wide range of use cases, including databases, enterprise applications, and data warehousing.

Why choose gp3?

Choosing gp3 over gp2 in Amazon Elastic Block Store (EBS) provides users with enhanced performance and flexibility. gp3 offers configurable IOPS and throughput, allowing users to tailor their storage performance to match the requirements of specific applications. With lower latency and higher baseline performance compared to gp2, gp3 delivers improved efficiency and responsiveness, making it ideal for latency-sensitive workloads or applications requiring higher I/O performance. Additionally, gp3's ability to scale performance independently of storage capacity ensures better value and cost optimization, making it a compelling choice for users seeking higher performance and flexibility in their storage solutions on AWS.

AWS EBS gp3 v/s gp2

How much costs can we save?

On average, if we are to take gp2 and migrate to gp3 with the baseline gp3 properties, such as IOPS and throughput, we get 20% savings.

But in some cases, the savings can also be between 10% to 19%. Let's look at them below.

So, if you choose to carry over the gp2 properties to gp3, then AWS will not provide the flat 20% discount. In most cases, you won't really need to carry over the properties unless you are noticing the IOPs and Throughput in the monitoring is actually more than required as per gp3.

How to migrate?

Let's see the migration steps needed!

Migrate via UI (less number of volumes)

  1. Visit:

  2. Select an existing gp2 Volume:

  3. Select Actions -> Modify Volume:

  4. Select gp3 from the dropdown and Modify:

That's it! You just saved 20% on this volume!

Migrate via CLI (high number of volumes)

When migrating a high number of volumes, UI is not suitable. So we will use AWS cli to the same

  1. Get a list of all the volumes in a region aws ec2 describe-volumes --region us-east-1

  2. Convert each volume with 1 command: aws ec2 modify-volume --volume-id vol-0e9d7e6146ed7fff3 --volume-type gp3 --region us-east-1

  3. To convert all, you can write a small script for the same

     # Set the AWS region
     # Get all volume IDs in the specified region
     volume_ids=$(aws ec2 describe-volumes --region $AWS_REGION --query 'Volumes[*].VolumeId' --output text)
     # Iterate over each volume and convert it to GP3
     for volume_id in $volume_ids; do
         echo "Converting volume $volume_id to gp3..."
         aws ec2 modify-volume --volume-id $volume_id --volume-type gp3 --region $AWS_REGION
         echo "Volume $volume_id converted to gp3."

If you like this, follow us on X and LinkedIn and explore our platform to help save you more cloud costs -