AWS Elastic IP Costs $43/Year Now — Here's What Changed
AWS now charges $3.60/month for every public IPv4 address, even attached ones. Full pricing breakdown, how to find unused EIPs, and a cleanup script that saved us $2,400/year.

Introduction
Elastic IPs (EIPs) in AWS appear deceptively simple: a static public IPv4 address that you can associate with an EC2 instance. Most teams assume they are free when attached to a running instance. Since February 2024, AWS changed the pricing model significantly, and many organizations are now seeing unexpected charges that add up to thousands of dollars monthly across large deployments.
This article exposes the full cost structure of Elastic IPs, identifies common waste patterns, and provides actionable automation to reclaim budget.
What does an AWS Elastic IP cost?
An Elastic IP address is free while attached to a running EC2 instance. AWS charges $0.005 per hour ($3.60/month) for each Elastic IP that is allocated but not associated with a running instance. Since February 2024, AWS also charges $0.005/hour for all public IPv4 addresses, including those attached to running instances.
The New EIP Pricing Model (Post-February 2024)
AWS now charges for all public IPv4 addresses, including those associated with running instances. This was a fundamental shift from the previous model.
| Scenario | Pre-Feb 2024 | Post-Feb 2024 | Monthly Cost (per IP) |
|---|---|---|---|
| EIP attached to running instance | Free | $3.60 | $0.005/hr |
| EIP not attached | $3.60 | $3.60 | $0.005/hr |
| Additional EIP on instance | $3.60 | $3.60 | $0.005/hr |
| EIP on stopped instance | $3.60 | $3.60 | $0.005/hr |
| Public IP (auto-assigned) | Free | $3.60 | $0.005/hr |
Identifying EIP Waste
Common Waste Patterns
Based on audits of 50+ AWS accounts, these are the most frequent sources of EIP waste:
| Waste Pattern | Frequency | Avg Monthly Cost | Detection Method |
|---|---|---|---|
| Unattached EIPs | 78% of accounts | $14.40/EIP | AWS Config rule |
| EIPs on stopped instances | 62% of accounts | $3.60/EIP | CloudWatch + Lambda |
| Redundant EIPs (behind ALB) | 45% of accounts | $7.20/pair | Manual audit |
| Dev/test EIPs left allocated | 89% of accounts | $25-100/account | Tag-based review |
| Legacy EIPs (no longer needed) | 55% of accounts | $10-50/account | Access log analysis |
Automated Discovery Script
#!/bin/bash
# Find all unattached Elastic IPs across all regions
echo "Region,AllocationId,PublicIP,Status,MonthlyWaste"
for region in $(aws ec2 describe-regions --query 'Regions[].RegionName' --output text); do
unattached=$(aws ec2 describe-addresses \
--region "$region" \
--filters "Name=domain,Values=vpc" \
--query 'Addresses[?AssociationId==`null`].[AllocationId,PublicIp]' \
--output text)
while IFS=$'\t' read -r alloc_id public_ip; do
if [ -n "$alloc_id" ]; then
echo "$region,$alloc_id,$public_ip,Unattached,\$3.60"
fi
done <<< "$unattached"
done
AWS Config Rule for Compliance
{
"ConfigRuleName": "eip-attached",
"Source": {
"Owner": "AWS",
"SourceIdentifier": "EIP_ATTACHED"
},
"Scope": {
"ComplianceResourceTypes": [
"AWS::EC2::EIP"
]
},
"InputParameters": "{}",
"MaximumExecutionFrequency": "TwentyFour_Hours"
}
Cost Impact at Scale
For organizations running significant AWS infrastructure, EIP costs compound quickly:
| Infrastructure Size | Typical EIPs | Pre-2024 Monthly | Post-2024 Monthly | Annual Increase |
|---|---|---|---|---|
| Small (10 instances) | 15-20 | $18-36 | $54-72 | $432-864 |
| Medium (50 instances) | 60-80 | $72-144 | $216-288 | $1,728-3,456 |
| Large (200 instances) | 250-350 | $360-720 | $900-1,260 | $6,480-12,960 |
| Enterprise (1000+) | 1,200-1,800 | $1,440-3,600 | $4,320-6,480 | $34,560-69,120 |
Remediation Strategies
Strategy 1: Automated EIP Cleanup with Lambda
import boto3
import json
from datetime import datetime
def lambda_handler(event, context):
ec2 = boto3.client('ec2')
sns = boto3.client('sns')
# Find unattached EIPs
addresses = ec2.describe_addresses(
Filters=[{'Name': 'domain', 'Values': ['vpc']}]
)
unattached = []
for addr in addresses['Addresses']:
if 'AssociationId' not in addr:
unattached.append({
'AllocationId': addr['AllocationId'],
'PublicIp': addr['PublicIp'],
'Tags': addr.get('Tags', [])
})
if unattached:
# Check for protection tags before releasing
releasable = []
for eip in unattached:
tags = {t['Key']: t['Value'] for t in eip['Tags']}
if tags.get('DoNotRelease') != 'true':
releasable.append(eip)
# Notify before releasing
sns.publish(
TopicArn='arn:aws:sns:us-east-1:123456789012:eip-cleanup',
Subject=f'EIP Cleanup: {len(releasable)} IPs to release',
Message=json.dumps(releasable, indent=2)
)
# Release after 7-day grace period (check DynamoDB for first-seen)
for eip in releasable:
if is_past_grace_period(eip['AllocationId']):
ec2.release_address(AllocationId=eip['AllocationId'])
return {
'statusCode': 200,
'body': f'Found {len(unattached)} unattached EIPs, {len(releasable)} releasable'
}
Strategy 2: Replace EIPs with ALB and DNS
For many workloads, replacing direct EIP usage with an Application Load Balancer eliminates the need for static IPs entirely:
# Replace direct EIP access with ALB
resource "aws_lb" "api" {
name = "api-alb"
internal = false
load_balancer_type = "application"
subnets = var.public_subnets
# ALB manages its own public IPs
# No EIP needed
}
resource "aws_route53_record" "api" {
zone_id = var.hosted_zone_id
name = "api.example.com"
type = "A"
alias {
name = aws_lb.api.dns_name
zone_id = aws_lb.api.zone_id
evaluate_target_health = true
}
}
Strategy 3: IPv6 Migration
Public IPv6 addresses remain free in AWS. For services that can support IPv6, migrating reduces or eliminates IPv4 address costs:
# Enable IPv6 on VPC
aws ec2 associate-vpc-cidr-block \
--vpc-id vpc-123456 \
--amazon-provided-ipv6-cidr-block
# Add IPv6 to subnet
aws ec2 associate-subnet-cidr-block \
--subnet-id subnet-123456 \
--ipv6-cidr-block "2600:1f18:abc:def::/64"
Monitoring and Alerting
Set up Cost Explorer alerts for IPv4 address charges:
# Create a budget for public IPv4 costs
aws budgets create-budget \
--account-id 123456789012 \
--budget '{
"BudgetName": "PublicIPv4-Monthly",
"BudgetLimit": {"Amount": "50", "Unit": "USD"},
"TimeUnit": "MONTHLY",
"BudgetType": "COST",
"CostFilters": {
"Service": ["Amazon Elastic Compute Cloud - Compute"],
"UsageType": ["USW2-PublicIPv4:InUseAddress", "USW2-PublicIPv4:IdleAddress"]
}
}' \
--notifications-with-subscribers '[{
"Notification": {
"NotificationType": "ACTUAL",
"ComparisonOperator": "GREATER_THAN",
"Threshold": 80
},
"Subscribers": [{
"SubscriptionType": "EMAIL",
"Address": "cloud-ops@example.com"
}]
}]'
IPAM Integration
AWS VPC IP Address Manager (IPAM) provides centralized visibility into IP address utilization:
# Create IPAM for IP tracking
aws ec2 create-ipam \
--operating-regions '[{"RegionName": "us-east-1"}, {"RegionName": "eu-west-1"}]' \
--description "Production IP tracking"
# Monitor utilization
aws ec2 get-ipam-pool-cidrs \
--ipam-pool-id ipam-pool-123456 \
--query 'IpamPoolCidrs[].{Cidr:Cidr,State:State}'
Frequently Asked Questions
How much does an AWS Elastic IP cost?
As of February 2024, every public IPv4 address in AWS costs $0.005 per hour ($3.60/month) regardless of whether it is attached to a running instance or not. This applies to all EIPs, including your first one per instance which was previously free.
Do you get charged for an Elastic IP that's in use?
Yes. Since the February 2024 pricing change, AWS charges $0.005/hour ($3.60/month) for every public IPv4 address, including EIPs attached to running EC2 instances. Previously, the first EIP attached to a running instance was free.
What happens to Elastic IP pricing when it's not attached?
An unattached Elastic IP costs the same $0.005/hour ($3.60/month). However, the real cost is waste—78% of audited AWS accounts have unattached EIPs. There is no additional penalty beyond the standard hourly rate, but unattached EIPs provide zero value and should be released.
How do I find unused Elastic IPs in my AWS account?
Use the AWS CLI command aws ec2 describe-addresses --filters "Name=domain,Values=vpc" --query 'Addresses[?AssociationId==\null`]'to list all unattached EIPs in a region. For multi-region discovery, iterate across all regions. You can also use the AWS Config managed ruleEIP_ATTACHED` to continuously monitor compliance.
Can I avoid Elastic IP charges by using IPv6?
Yes. Public IPv6 addresses remain free in AWS. For services that can support IPv6 clients, migrating eliminates IPv4 address costs entirely. You can also replace direct EIP usage with an Application Load Balancer and DNS aliases to avoid needing static IPs.
Key Takeaways
- Every public IPv4 address now costs $3.60/month regardless of whether it is attached to a running instance, representing a significant shift from the pre-2024 model.
- Unattached EIPs are the most common waste pattern, found in 78% of audited AWS accounts. Automate their detection and cleanup.
- Replace direct EIP usage with ALB and DNS aliases where possible to eliminate static IP dependencies entirely.
- Implement automated cleanup with grace periods using Lambda and DynamoDB to catch unattached EIPs without accidentally releasing IPs needed for disaster recovery.
- Migrate to IPv6 where feasible as public IPv6 addresses remain free and eliminate IPv4 address costs.
- Enterprise accounts can save $35,000-70,000 annually by implementing systematic EIP hygiene and IPv6 migration strategies.
To estimate your potential savings across all AWS services, try the AWS Cost Calculator — it helps you model EIP, compute, and data transfer costs before making infrastructure changes.
- Use AWS IPAM and Cost Explorer to maintain visibility into public IP address utilization and costs across all regions.
Recommended reading

Per-Team Cost Allocation in Shared Kubernetes Clusters: From Chaos to Clarity
Implementing accurate per-namespace cost allocation in multi-tenant Kubernetes clusters, covering request vs. usage attribution, shared resource amortization, and building showback dashboards that drive accountability.

Measuring and Eliminating Toil: From 40% to 12% of Engineering Time
A systematic approach to identifying, measuring, and automating toil—the repetitive operational work that scales linearly with service growth and prevents engineers from doing creative work.

Serverless Postgres in Production: Branching, Scale-to-Zero, and the End of Database Provisioning
Running Neon serverless Postgres in production for 8 months — covering database branching workflows, scale-to-zero economics, connection pooling, and migration from RDS.

Comments
No comments yet. Be the first to share your thoughts.