Load Balancer

Networking

Also known as: L4 load balancer, L7 load balancer

A load balancer distributes incoming network traffic across multiple servers to ensure no single server is overwhelmed, improving availability and responsiveness of applications.

Load balancers sit between clients and servers, routing each request to an appropriate backend server based on a chosen algorithm. Common algorithms include round-robin, least connections, and IP hash.

In system design, load balancers are critical at multiple layers: Layer 4 (transport) balancers route based on IP and port, while Layer 7 (application) balancers can inspect HTTP headers, cookies, or URL paths to make smarter routing decisions.

Load balancers also perform health checks on backend servers, automatically removing unhealthy instances from the pool and re-adding them when they recover. This makes them a key component for achieving high availability.

Popular implementations include NGINX, HAProxy, and cloud-native solutions like AWS ALB/NLB and Google Cloud Load Balancing.

Related Terms

Practice This Concept

Ready to design?

Practice using load balancer in a real system design on Supaboard's interactive whiteboard.

Browse Challenges