AWS ELB Pricing & Optimization Guide

Author Nikhila Jain

Last updated 25 May, 2023

6 mins read

AWS ELB Pricing & Optimization Guide - pricing and optimization guide

Elastic Load Balancing (ELB) is a load-balancer service provided by Amazon. It automatically distributes internet traffic to your server instances, like EC2, containers, or any underlying service sitting behind it in one or more availability zones.

If any of your server instances fail, you certainly don’t want those failures to be visible to your end users. ELB plays a vital role in managing a seamless user access experience across your applications by monitoring the health of its registered instances and directing the traffic flow to only healthy or active instances.

In this guide, you will learn about the types of load balancers provided by Amazon, their pricing models, and some quick tips for optimizing costs associated with them.

AWS ELB Pricing

The Elastic Load Balancing offered by Amazon has four flavors to choose from: Application Load Balancer, Network Load Balancer, Gateway Load Balancer, and Classic Load Balancer. Each of these load balancers offers high availability, automatic scaling, and strong security support for your applications.

ELB pricing also follows an AWS rule: “You only pay for what you use with your setup.” To properly bill you for your ELB usage, AWS has introduced a component called the Load Balancer Capacity Unit (LCU), which is an integral part of your billing calculation, along with the region you host your infrastructure.

The LCU is a metric that defines the maximum consumption of a resource in any one of these dimensions: new connections/flows, active connections/flows, and bandwidth and traffic processed by ELB. These LCUs are called Network Load Capacity Units (NLCUs) and Gateway Load Capacity Units (GLCU) for Network and Gateway Load Balancers, respectively.

The Classic Load Balancer billing is not done using the LCU metric, and for an Application Load Balancer, rule evaluations are considered an additional parameter to derive LCU consumption.

Let’s dive into each of the load balancers to understand their pricing models.

Application Load Balancer

The Application Load Balancer (ALB) works at an application layer that deals with HTTP/HTTPS traffic. It gives you the flexibility to define a wide range of rules on the incoming requests and, based on that, routes the request to underlining services.

ALB Pricing Model

AWS bills an ALB either per hour or partial hour, along with the number of LCU used per hour.

Use Case

Let’s assume that your application receives an average of twenty new connections per second and that each connection is active for one second. A client sends twenty requests per second and processes 1 GB of data per hour. You have configured five rules on the load balancer for evaluating client requests.

Calculation

Note
RegionUS East (Ohio)
Standard charge for each load balancer$0.0225
Standard charge for each LCU per hour$0.008
Calculation TypeFormulaEvaluationFinal ValueAWS Statistics
ALB chargenumber of load balancers * 0.0225 (AWS standard cost) * hours per month1 * 0.0225 * 730$16.43AWS assumes 730 hours on a monthly billing cycle
New connection LCUgiven new connections / new connections provided by LCU20/250.80each LCU provides 25 connections per second, averaged over an hour
Active connection LCUgiven active connections / provided active connections20/3,0000.00666666666666667each LCU provides 3,000 active connections
Rule evaluation LCUmax ((rule processed by application – free rules per request), $0)max ((5-10), 0) = Max (-5, 0)010 free rule evaluations are provided
Data processed LCUdata processed by LCU / data provided by LCU1/11each LCU provides 1 GB of data
LCU costmax (new connections, active connections, data processed, rule evaluations)max (0.80, 0.00666666666666667, 0, 1)1
Total ALB LCU costnumber of load balancers * consumed LCUs * 0.008 * hours in a month1 * 1 * 0.008 * 730$5.84AWS assumes 730 hours on a monthly billing cycle
Total configuration charge on a monthly billmonthly load balancer charge + monthly LCU charge16.43 + 5.84$22.27

Thus, for this use case, the monthly bill generated by AWS will be $22.27.

Network Load Balancer

The Network Load Balancer (NLB) works at layer 4 and can handle TCP, UDP, and TLS traffic. It is the most performant ELB and works with static IP addresses. You can also assign one elastic IP address per subnet. NLB supports registering targets by IP address, including the targets that are outside your load balancer VPC.

NLB Pricing Model

AWS billing for an NLB is either per hour or partial hour, along with the number of NLCU consumed.

Use Case

Let’s assume that your application receives an average of twenty new TCP connections per second and each connection is active for one second. A client processes 1 GB of data per hour.

Calculation

Note
RegionUS East (Ohio)
Standard charge for each load balancer$0.0225
Standard charge for each LCU per hour$0.006
Calculation TypeFormulaEvaluationFinal ValueAWS Statistics
NLB chargenumber of load balancers * 0.0225 (AWS standard cost) * hours per month1 * 0.0225 * 730$16.43AWS assumes 730 hours on a monthly billing cycle
New TCP connection LCUgiven new TCP connections / new TCP connections provided by LCU20/8000.025each LCU provides 800 connections per second averaged over an hour
Active TCP connection LCUgiven active connections / provided active connections20/3,0000.0002each LCU provides 3,000 active connections
Data processed LCUdata processed by LCU / data provided by LCU1/11each LCU provides 1 GB of data
LCU costmax (new TCP connections, active TCP connections, data processed)max (0.025, 0.0002, 1)1
Total NLB LCU costnumber of load balancers * consumed LCUs * 0.006 * hours in a month1 * 1 * 0.006 * 730$4.38AWS assumes 730 hours on a monthly billing cycle
Total configuration charge on a monthly billmonthly load balancer charge + monthly LCU charge16.43 + 4.38$20.81

Thus, for this use case, the monthly bill generated by AWS will be $20.81.

Gateway Load Balancer

The Gateway Load Balancer (GWLB) works at the third layer and enables you to deploy, scale, and manage virtual appliances, such as firewalls and prevention and detection systems.

GLB Pricing Model

AWS bills a GWLB either per hour or partial hour, along with the number of GLCU used by the GWLB per hour.

Use Case

Let’s assume that your GWLB is configured to handle single-zone deployment with twenty new connections per second and each connection is active for one second and consumes 1 GB of data per hour.

Calculation

Note
RegionUS East (Ohio)
Standard charge for each load balancer$0.0125
Standard charge for each LCU per hour$0.004
Standard charge for each endpoint$0.01
Standard data processing charge for endpoint$0.0035
Calculation TypeFormulaEvaluationFinal ValueAWS Statistics
GWLB chargenumber of load balancers * 0.0225 (AWS standard cost) * hours per month1 * 0.0125 * 730$9.13AWS assumes 730 hours on a monthly billing cycle
New connection LCUgiven new connections / new connections provided by LCU20/6000.0333333333333333each LCU provides 600 connections per second averaged over an hour
Active connection LCUgiven active connections / provided active connections20/60,0000.000333333333333333each LCU provides 60,000 active connections
Data processed LCUdata processed by LCU / data provided by LCU1 /11each LCU provides 1 GB of data
LCU costmax (new connections, active connections, data processed)max (0.0003333333333333333, 0.0003333333333333333, 1)1
Total GWLB LCU costnumber of load balancers * consumed LCUs * 0.004 * hours in a month1 * 1 * 0.004 * 730$2.92AWS assumes 730 hours on a monthly billing cycle
GWLB endpointnumber of load balancer endpoints * 0.01 * hours in a month1 * 0.01 * 730$7.30AWS assumes 730 hours on a monthly billing cycle
GWLB endpoint data processingdata processed per hour * 0.0035 * hours in a month1 * 0.0035 * 730$2.56AWS assumes 730 hours on a monthly billing cycle
Total configuration charge on a monthly billmonthly load balancer charge + monthly LCU charge + monthly endpoint charge + monthly endpoint data processing charge9.13 + 2.92 + 7.30 + 2.56$21.91

Thus, for this GWLB use case, the monthly bill generated by AWS will be $21.91.

Classic Load Balancer

The Classic Load Balancer (CLB) provides basic load balancing across multiple EC2 instances. It operates at the request as well as at the connection level.

CLB Pricing Model

AWS bills a CLB either per hour or partial hour for each gigabyte of data transferred. The CLB pricing does not include the LCU metric.

Use Case

Let’s assume here that one CLB is used to handle the traffic routing of multiple EC2 instances and consumes 1 GB of data per hour.

Calculation

The cost of running CLB per hour or partial hour can be calculated by determining the following: number of load balancers * 0.025 per hour (this is the standard cost used by AWS for US East [Ohio] region) * number of hours in a day * number of days in a month. Remember that AWS assumes there are 730 hours on a monthly billing cycle.

Calculation TypeFormulaEvaluationFinal ValueAWS Statistics
CLB chargenumber of load balancers * 0.025 * hours in a month1 * 0.025 * 730$18.25AWS assumes 730 hours on a monthly billing cycle
Data processed by CLBdata processed per hour * hours in a month1 * 730730 GBAWS assumes 730 hours on a monthly billing cycle
Data processing chargenumber of load balancers * data processed in a month * 0.0081 * 730 * 0.008$5.84
Total CLB costCLB charge + data processing charge18.25 + 5.84$24.09

Thus, for this CLB use case, the monthly bill generated by AWS will be $24.09.

ELB Cost Optimization

To manage your ELB costs, it’s imperative that you choose the right ELB for your infrastructure setup. Thus, it’s essential to understand the key comparison factors among the load balancers.

FeaturesClassic Load BalancerApplication Load BalancerNetwork Load Balancer
Protocol supportTCP, SSL/TLS, HTTP, HTTPSHTTP, HTTPSTCP, TLS
PerformanceModerateSlowestFastest
Path routingNot supportedYesNot supported
Sticky sessionsYes, redirected to same machineYes, redirected to same targetNot supported
Static/Elastic IPNot supportedNot supportedYes
Load balancing for multiple portsNot supportedYesYes
Idle connection configurationYesYesNo
Preserve source IPNot supportedNot supportedYes
Support targets outside AWSNot supportedYesYes
Cost differences per use case configuration$24.09$22.27$20.81

You can see that the cost differences among each ELB are not huge, but what is most important is to choose from the features provided by each that best suits your system requirements.

Conclusion

ELB provides high availability and fault tolerance of your applications evenly distributes traffic to registered instances, and effectively manages peaks. However, if you’re not careful, the ELB AWS pricing model can make your cost exponentially shoot up.

AWS ELB cost optimization starts with understanding your system requirements using monitoring tools, like AWS Cost Explorer, CloudWatch, and CloudForecast. With these tools in place, you can easily calculate your cost against your resources and create your AWS ELB budget plan.

CloudForecast provides an interactive dashboard that helps you effectively analyze, plan, and manage your costs. If you need help in visualizing your AWS ELB costs, CloudForecast is ready to assist.

Author Nikhila Jain
Nikhila Jain is a tech blogger who formerly worked as a technical lead and architect in the information technology space. With sixteen years of experience working in technologies like Java, Amazon services, Microservices, Project, and Team management, she wanted to blend her passion for writing with technology and help techies explore new domains.

Manage, track, and report your AWS spending in seconds — not hours

CloudForecast’s focused daily AWS cost monitoring reports to help busy engineering teams understand their AWS costs, rapidly respond to any overspends, and promote opportunities to save costs.

Monitor & Manage AWS Cost in Seconds — Not Hours

CloudForecast makes the tedious work of AWS cost monitoring less tedious.

AWS cost management is easy with CloudForecast

We would love to learn more about the problems you are facing around AWS cost. Connect with us directly and we’ll schedule a time to chat!

AWS daily cost reports