Repaso
Español
Cloud & DevOpsIntermediateOPS-58

What is the difference between an Application Load Balancer (ALB) and a Network Load Balancer (NLB)?

Options

  1. ALB works at layer 7 with path routing; NLB works at layer 4 for speed (Correct option)
  2. They are identical and only differ in the price of each hour
  3. ALB is meant for databases; NLB is meant for web traffic
  4. NLB understands URLs and paths; ALB does not understand them

Answer

ALB works at layer 7 (HTTP/HTTPS) with path/host routing; NLB works at layer 4 (TCP/UDP) for very high performance and static IPs

Why

Layers refer to the network model: layer 4 = transport (TCP/UDP ports), layer 7 = application (HTTP).

  • ALB: understands HTTP, so it can route /api/* to one service and /web/* to another, terminate TLS, and integrate with WAF.
  • NLB: forwards TCP/UDP connections without reading HTTP; ultra-low latency, millions of requests, fixed IPs.

Azure equivalents: Application Gateway (layer 7) and Azure Load Balancer (layer 4); Azure Front Door is a global layer 7.

Remember

ALB = L7 HTTP routing. NLB = L4 TCP speed.

Key terms

Practice this question in Repaso