Layer 7 Load Balancer - HTTP/HTTPS Traffic Handler

image.png

EC2 instances see the Load Balancer's IP, not the client's IP. The true client IP is available in the X-Forwarded-For header.

Application Load Balancer operates at Layer 7 (Application Layer) and understands HTTP/HTTPS traffic. It can make intelligent routing decisions based on request content.

ALB is a Layer 7 load balancer — meaning it understands HTTP and HTTPS traffic. It can read the content of a request (URL, headers, query parameters) and decide where to send it based on that.

A basic load balancer just distributes traffic evenly. ALB goes further — it can look at the request and say "this is going to /users, send it to the user service" or "this is a mobile request, send it to the mobile servers."


Key Features

Layer 7 — Understands Web Traffic

Protocol Support

Multiple Apps, One ALB

Instead of having a separate load balancer for each service (expensive), one ALB can handle all of them.

Without ALB (separate LB per app):
App 1 LB: $55/month
App 2 LB: $55/month
App 3 LB: $55/month
Total:    $165/month

With one ALB:
One ALB routes to all 3 apps: $22/month

Routing — How ALB Decides Where to Send Traffic