AWS Cost Optimization: Extra IPV4 Cost Per Hour For Public IP
June 01, 2024 • 5 min read

Image Banner

Background

Recently, AWS introduced a $0.005 dollar cost per hour for each in-use public IPV4 address in a VPC whether attached to a service or not. According to Amazon, 750 hours of public IPv4 address usage per month is only Free when you are using the Public IP with EC2 service and your AWS Account is under Free tier. If you are using Public IP with any other service than EC2 or Free Tier is expired on the account, then a charge of $0.005 per IP per hour will be present on the account.

screenshot

From this screenshot above you can clearly see that the only thing i got charged for was the public IP

Common Scenarios

Some operations can result in a public IP address being allocated to your account which is not coming directly from the EC2 instance, the most common on will probably be from your Relational Database Service (RDS), if you use one.

On your RDS, if you had set it to be publicly accessible, AWS would allocate a public IP to it to make it accessible outside the VPC. As a user still on free tier, you may not know this and will be shocked at month end when AWS emails you your bill for the month 😅

screenshot

To resolve this, if you don't need to access your database outside your VPC, then you just have to edit the configuration disable public access.


2024 Anthony Nwobodo