{"id":9143,"date":"2026-10-10T13:34:35","date_gmt":"2026-10-10T13:34:35","guid":{"rendered":"https:\/\/prwatech.in\/blog\/?p=9143"},"modified":"2026-10-11T13:26:49","modified_gmt":"2026-10-11T13:26:49","slug":"load-balancing","status":"publish","type":"post","link":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/","title":{"rendered":"Load Balancing"},"content":{"rendered":"\r\n<h1><strong><b>How to Set Up HTTP Load Balancing on Google Cloud<\/b><\/strong><\/h1>\r\n<p class=\"wp-block-paragraph\">Every website or application eventually hits the same problem. One server cannot handle all the traffic, and if that one server fails, everything goes down with it. A load balancer solves both problems. It sits in front of several identical servers, shares incoming requests between them, and quietly stops sending traffic to any server that stops responding.<\/p>\r\n<p>Google Cloud gives you a managed load balancer that does this without you running any load balancing software. You create the pieces in the console: a group of virtual machines, a health check that decides which machines are healthy, a backend service that points at the group, and a frontend that gives users one address to visit. Google then spreads the traffic for you and scales the load balancer itself as demand grows.<\/p>\r\n<p>In this guide you will build a complete HTTP load balancer from scratch. We begin with when load balancing is the right tool and which type to choose. Then we build an instance group with a template and a startup script that installs the Apache web server, set up autoscaling, open the firewall, and create the load balancer with its backend, health check and frontend. Every original screenshot stays in place. At the end you will find a short section on load balancing inside Google Kubernetes Engine, plus common mistakes, a short FAQ and how to clean up.<\/p>\r\n<h2><strong><b>When to Use Load Balancing<\/b><\/strong><\/h2>\r\n<p>Reach for a load balancer when any of these are true:<\/p>\r\n<ul>\r\n<li>One server is no longer enough for your traffic.<\/li>\r\n<li>You cannot afford downtime if a single machine fails.<\/li>\r\n<li>Your traffic rises and falls and you want machines added and removed automatically.<\/li>\r\n<li>You want one stable address for users while servers change behind it.<\/li>\r\n<\/ul>\r\n<p>Google Cloud offers several load balancer types. The right one depends on the traffic you carry and who sends it.<\/p>\r\n<div style=\"width: 100%; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 20px 0; border: 1px solid #d9e0ea; border-radius: 8px;\">\r\n<table style=\"width: 100%; min-width: 600px; border-collapse: collapse; font-family: Arial,Helvetica,sans-serif; font-size: 16px; line-height: 1.5; color: #1f2937;\"><caption style=\"caption-side: top; text-align: left; padding: 12px 14px; font-size: 18px; font-weight: bold; color: #0f2a4a;\">Types of Google Cloud load balancers<\/caption>\r\n<thead>\r\n<tr style=\"background: #0f2a4a;\">\r\n<th style=\"padding: 12px 14px; text-align: left; color: #ffffff; font-weight: bold; border-bottom: 2px solid #0b1f38; width: 28%;\" scope=\"col\">Type<\/th>\r\n<th style=\"padding: 12px 14px; text-align: left; color: #ffffff; font-weight: bold; border-bottom: 2px solid #0b1f38; width: 36%;\" scope=\"col\">Works with<\/th>\r\n<th style=\"padding: 12px 14px; text-align: left; color: #ffffff; font-weight: bold; border-bottom: 2px solid #0b1f38;\" scope=\"col\">Use it for<\/th>\r\n<\/tr>\r\n<\/thead>\r\n<tbody>\r\n<tr style=\"background: #ffffff;\">\r\n<th style=\"padding: 12px 14px; text-align: left; font-weight: 600; vertical-align: top; border-bottom: 1px solid #e5e9f0;\" scope=\"row\">Application Load Balancer<\/th>\r\n<td style=\"padding: 12px 14px; vertical-align: top; border-bottom: 1px solid #e5e9f0;\">HTTP and HTTPS traffic<\/td>\r\n<td style=\"padding: 12px 14px; vertical-align: top; border-bottom: 1px solid #e5e9f0;\">Websites and web applications, the type built in this guide<\/td>\r\n<\/tr>\r\n<tr style=\"background: #f5f8fc;\">\r\n<th style=\"padding: 12px 14px; text-align: left; font-weight: 600; vertical-align: top; border-bottom: 1px solid #e5e9f0;\" scope=\"row\">Proxy Network Load Balancer<\/th>\r\n<td style=\"padding: 12px 14px; vertical-align: top; border-bottom: 1px solid #e5e9f0;\">TCP traffic with a proxy<\/td>\r\n<td style=\"padding: 12px 14px; vertical-align: top; border-bottom: 1px solid #e5e9f0;\">Non HTTP services that need global reach or SSL offload<\/td>\r\n<\/tr>\r\n<tr style=\"background: #ffffff;\">\r\n<th style=\"padding: 12px 14px; text-align: left; font-weight: 600; vertical-align: top; border-bottom: 1px solid #e5e9f0;\" scope=\"row\">Passthrough Network Load Balancer<\/th>\r\n<td style=\"padding: 12px 14px; vertical-align: top; border-bottom: 1px solid #e5e9f0;\">TCP, UDP and other protocols, regional<\/td>\r\n<td style=\"padding: 12px 14px; vertical-align: top; border-bottom: 1px solid #e5e9f0;\">Services that need the client IP kept or non web protocols<\/td>\r\n<\/tr>\r\n<tr style=\"background: #f5f8fc;\">\r\n<th style=\"padding: 12px 14px; text-align: left; font-weight: 600; vertical-align: top;\" scope=\"row\">Internal load balancers<\/th>\r\n<td style=\"padding: 12px 14px; vertical-align: top;\">Traffic inside your VPC network<\/td>\r\n<td style=\"padding: 12px 14px; vertical-align: top;\">Private services that only other systems call<\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n<\/div>\r\n<p>&nbsp;<\/p>\r\n<p>The console names for these types have changed over the years, so confirm the exact labels in your project. This guide builds an external HTTP load balancer, which is the usual choice for a public website.<\/p>\r\n<p><strong>Prerequisites:<\/strong><\/p>\r\n<ul>\r\n<li>A Google Cloud account with a project that has billing enabled.<\/li>\r\n<li>The Compute Engine API enabled in that project.<\/li>\r\n<li>A role that can create instances, firewall rules and load balancers, such as Compute Admin and Network Admin.<\/li>\r\n<li>Time to clean up afterwards. Load balancers and instances bill while they exist.<\/li>\r\n<\/ul>\r\n<h2><strong><b>Step by Step Process of Setting Up HTTP Load Balancing<\/b><\/strong><\/h2>\r\n<h3><strong><b>Step 1: Create the Instance Group<\/b><\/strong><\/h3>\r\n<p>An instance group is the set of identical virtual machines that will sit behind the load balancer. A managed instance group creates them from a template, which is what lets Google add and remove machines automatically.<\/p>\r\n<ol>\r\n<li>In the console, open Compute Engine and then Instance groups. Click <strong><b>Create instance group<\/b><\/strong>.<\/li>\r\n<li>Give the group a name, and choose the region and zone.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"342\" height=\"213\" class=\"wp-image-9145\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png 342w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467-300x187.png 300w\" sizes=\"auto, (max-width: 342px) 100vw, 342px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on Create Instance\u00a0Group<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"406\" height=\"353\" class=\"wp-image-9146\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-468.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-468.png 406w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-468-300x261.png 300w\" sizes=\"auto, (max-width: 406px) 100vw, 406px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give a name for instance group.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Select the Region and Zone<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"418\" height=\"320\" class=\"wp-image-9147\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-469.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-469.png 418w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-469-300x230.png 300w\" sizes=\"auto, (max-width: 418px) 100vw, 418px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 2: Create the Instance Template<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">The template is the blueprint every machine in the group is built from.<\/p>\r\n<ol>\r\n<li>Under Instance template, choose to create a new template.<\/li>\r\n<li>Set the machine configuration. A small machine type is enough for this exercise.<\/li>\r\n<li>In the firewall section, allow HTTP traffic so that web requests can reach the machines.<\/li>\r\n<\/ol>\r\n<p>&nbsp;<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"482\" height=\"155\" class=\"wp-image-9148\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-470.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-470.png 482w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-470-300x96.png 300w\" sizes=\"auto, (max-width: 482px) 100vw, 482px\" \/><\/figure>\r\n<p>&nbsp;<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give a new Instance Template.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Choose the Specification for instance template.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"418\" height=\"419\" class=\"wp-image-9149\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-471.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-471.png 418w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-471-300x300.png 300w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-471-150x150.png 150w\" sizes=\"auto, (max-width: 418px) 100vw, 418px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">In firewall, Tick Allow.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click Management, security, disks, networking, sole tenancy<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"397\" height=\"151\" class=\"wp-image-9150\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-472.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-472.png 397w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-472-300x114.png 300w\" sizes=\"auto, (max-width: 397px) 100vw, 397px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 3: Add the Startup Script<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">Under the Management section, paste a startup script. It runs when each machine boots and installs the Apache web server, so every machine in the group serves a web page without you logging in to any of them.<\/p>\r\n<p>#! \/bin\/bash<\/p>\r\n<p>apt-get update<\/p>\r\n<p>apt-get install apache2 -y<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"414\" height=\"369\" class=\"wp-image-9152\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-473.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-473.png 414w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-473-300x267.png 300w\" sizes=\"auto, (max-width: 414px) 100vw, 414px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\"><strong><b>Tip:<\/b><\/strong>\u00a0make each machine show its own name on the default page, so you can see the load balancer sharing requests. Add this line after the install line:<\/p>\r\n<p>echo &#8220;Served by $(hostname)&#8221; &gt; \/var\/www\/html\/index.html<\/p>\r\n<h3><strong><b>Step 4: Set the Network Tag<\/b><\/strong><\/h3>\r\n<ol>\r\n<li>Under Networking, add a network tag such as http-server. Firewall rules use this tag to find your machines.<\/li>\r\n<li>Click <strong><b>Save and continue<\/b><\/strong>to finish the template.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"428\" height=\"241\" class=\"wp-image-9153\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-474.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-474.png 428w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-474-300x169.png 300w\" sizes=\"auto, (max-width: 428px) 100vw, 428px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Then Click Save and Continue<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"428\" height=\"386\" class=\"wp-image-9154\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-475.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-475.png 428w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-475-300x271.png 300w\" sizes=\"auto, (max-width: 428px) 100vw, 428px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 5: Configure Autoscaling<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">Autoscaling lets the group add machines when they are busy and remove them when they are idle. That keeps cost down and capacity up.<\/p>\r\n<ol>\r\n<li>Set the autoscaling mode to scale automatically, and choose CPU utilisation as the signal.<\/li>\r\n<li>Set a target percentage, for example 60 percent, and click <strong><b>Done<\/b><\/strong>.<\/li>\r\n<li>Set the minimum and maximum number of instances. Two and four are fine for a test.<\/li>\r\n<li>For autohealing, choose no health check for now, since the load balancer will have its own. Then click <strong><b>Create<\/b><\/strong>.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"478\" height=\"325\" class=\"wp-image-9156\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-476.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-476.png 478w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-476-300x204.png 300w\" sizes=\"auto, (max-width: 478px) 100vw, 478px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give the metric type as CPU Utilization and give the target percentage.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click Done.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"439\" height=\"299\" class=\"wp-image-9157\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-477.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-477.png 439w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-477-300x204.png 300w\" sizes=\"auto, (max-width: 439px) 100vw, 439px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give the minimum and maximum number of instances. In autohealiing, Give No health Check.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Then Click Create.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"409\" height=\"486\" class=\"wp-image-9158\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-478.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-478.png 409w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-478-252x300.png 252w\" sizes=\"auto, (max-width: 409px) 100vw, 409px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 6: Map the Port Name<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">The load balancer finds the right port on your machines through a named port. You attach the name http to port 80 on the instance group.<\/p>\r\n<ol>\r\n<li>Open the new instance group and click <strong><b>Edit<\/b><\/strong>.<\/li>\r\n<li>Find Specify port name mapping.<\/li>\r\n<li>Add the name http with the port number 80.<\/li>\r\n<li>Click <strong><b>Save<\/b><\/strong>.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"534\" height=\"237\" class=\"wp-image-9159\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-479.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-479.png 534w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-479-300x133.png 300w\" sizes=\"auto, (max-width: 534px) 100vw, 534px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">\u00a0Edit.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"416\" height=\"333\" class=\"wp-image-9160\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-480.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-480.png 416w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-480-300x240.png 300w\" sizes=\"auto, (max-width: 416px) 100vw, 416px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on Specify port name mapping.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"448\" height=\"217\" class=\"wp-image-9161\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-481.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-481.png 448w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-481-300x145.png 300w\" sizes=\"auto, (max-width: 448px) 100vw, 448px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on Add item.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"465\" height=\"177\" class=\"wp-image-9162\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-482.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-482.png 465w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-482-300x114.png 300w\" sizes=\"auto, (max-width: 465px) 100vw, 465px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give the port name as http and port number as 80.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"448\" height=\"164\" class=\"wp-image-9163\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-483.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-483.png 448w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-483-300x110.png 300w\" sizes=\"auto, (max-width: 448px) 100vw, 448px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Save.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"474\" height=\"138\" class=\"wp-image-9164\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-484.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-484.png 474w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-484-300x87.png 300w\" sizes=\"auto, (max-width: 474px) 100vw, 474px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 7: Create the Firewall Rule<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">A firewall rule lets web traffic and the health check probes reach your machines.<\/p>\r\n<ol>\r\n<li>Open VPC network and then Firewall, and click <strong><b>Create firewall rule<\/b><\/strong>.<\/li>\r\n<li>Give the rule a name, and set the target tag to the one you added to the template.<\/li>\r\n<li>For source IP ranges, add the health check ranges 130.211.0.0\/22 and 35.191.0.0\/16, and the range of the users you want to allow. Use 0.0.0.0\/0 only for a public test site.<\/li>\r\n<li>Allow TCP port 80 and click <strong><b>Create<\/b><\/strong>.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"410\" height=\"227\" class=\"wp-image-9165\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-485.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-485.png 410w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-485-300x166.png 300w\" sizes=\"auto, (max-width: 410px) 100vw, 410px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">\u00a0on create Firewall.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"515\" height=\"213\" class=\"wp-image-9166\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-486.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-486.png 515w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-486-300x124.png 300w\" sizes=\"auto, (max-width: 515px) 100vw, 515px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give the name\u00a0 for firewall<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"552\" height=\"283\" class=\"wp-image-9167\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-487.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-487.png 552w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-487-300x154.png 300w\" sizes=\"auto, (max-width: 552px) 100vw, 552px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">the target tags.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give the Source IP ranges<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Select the tcp and give port number as 80<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"499\" height=\"495\" class=\"wp-image-9168\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-488.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-488.png 499w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-488-300x298.png 300w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-488-150x150.png 150w\" sizes=\"auto, (max-width: 499px) 100vw, 499px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 8: Reserve a Static IP Address<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">A static address gives your load balancer a front door that never changes. Reserve one in the console under VPC network and then IP addresses.<\/p>\r\n<ol>\r\n<li>Open the external IP addresses page.<\/li>\r\n<li>Reserve a new static address, give it a name and click <strong><b>Reserve<\/b><\/strong>.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"400\" height=\"221\" class=\"wp-image-9169\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-489.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-489.png 400w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-489-300x166.png 300w\" sizes=\"auto, (max-width: 400px) 100vw, 400px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">In the \u00a0Type, Click on Ephemeral.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"370\" height=\"193\" class=\"wp-image-9170\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-490.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-490.png 370w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-490-300x156.png 300w\" sizes=\"auto, (max-width: 370px) 100vw, 370px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Change it into static.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"288\" height=\"125\" class=\"wp-image-9171\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-491.png\" alt=\"\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give the name for static and Click reserve.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"530\" height=\"347\" class=\"wp-image-9172\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-492.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-492.png 530w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-492-300x196.png 300w\" sizes=\"auto, (max-width: 530px) 100vw, 530px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on network services &gt; Load balancing<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"456\" height=\"283\" class=\"wp-image-9173\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-493.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-493.png 456w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-493-300x186.png 300w\" sizes=\"auto, (max-width: 456px) 100vw, 456px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\"><strong><b>Check:<\/b><\/strong>\u00a0reserve this address as its own resource, not by converting a virtual machine address, and select it later in the frontend configuration. Converting a machine address would keep the machine address, not the load balancer address.<\/p>\r\n<h3><strong><b>Step 9: Create the Load Balancer<\/b><\/strong><\/h3>\r\n<ol>\r\n<li>Open Network services and then Load balancing, and click <strong><b>Create load balancer<\/b><\/strong>.<\/li>\r\n<li>Choose the HTTP and HTTPS option and click <strong><b>Start configuration<\/b><\/strong>.<\/li>\r\n<li>Choose From internet to my VMs, which means the traffic comes from the public internet.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"444\" height=\"206\" class=\"wp-image-9174\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-494.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-494.png 444w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-494-300x139.png 300w\" sizes=\"auto, (max-width: 444px) 100vw, 444px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">In HTTP load balancing, Click on Start configuration<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"370\" height=\"299\" class=\"wp-image-9175\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-495.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-495.png 370w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-495-300x242.png 300w\" sizes=\"auto, (max-width: 370px) 100vw, 370px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Select From internet to my VM\u2019s and Click Continue.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"476\" height=\"234\" class=\"wp-image-9176\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-496.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-496.png 476w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-496-300x147.png 300w\" sizes=\"auto, (max-width: 476px) 100vw, 476px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">In the Backend Configuration. Select\u00a0 Backend Services &gt; Create a backend service.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9177\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-497.png\" alt=\"\" width=\"653\" height=\"248\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-497.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-497-300x114.png 300w\" sizes=\"auto, (max-width: 653px) 100vw, 653px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 11: Add a Health Check<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">The health check is how the load balancer knows which machines are working. It sends a small request to each one and stops sending traffic to any that fail to answer.<\/p>\r\n<ol>\r\n<li>Create a new health check, choose the HTTP protocol and port 80.<\/li>\r\n<li>Click <strong><b>Save and continue<\/b><\/strong>, then <strong><b>Create<\/b><\/strong>.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"435\" height=\"251\" class=\"wp-image-9178\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-498.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-498.png 435w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-498-300x173.png 300w\" sizes=\"auto, (max-width: 435px) 100vw, 435px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Select the created Instance Group. Give the port number as 80.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click Done.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"393\" height=\"427\" class=\"wp-image-9179\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-499.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-499.png 393w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-499-276x300.png 276w\" sizes=\"auto, (max-width: 393px) 100vw, 393px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 12: Configure the Frontend<\/b><\/strong><\/h3>\r\n<ol>\r\n<li>Open the frontend configuration, give it a name and set the protocol to HTTP.<\/li>\r\n<li>Select the static IP address you reserved earlier, then click <strong><b>Done<\/b><\/strong>.<\/li>\r\n<li>Give the load balancer a name and click <strong><b>Create<\/b><\/strong>.<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"474\" height=\"748\" class=\"wp-image-9180\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-500.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-500.png 474w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-500-190x300.png 190w\" sizes=\"auto, (max-width: 474px) 100vw, 474px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Then Click Create<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"434\" height=\"315\" class=\"wp-image-9181\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-501.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-501.png 434w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-501-300x218.png 300w\" sizes=\"auto, (max-width: 434px) 100vw, 434px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3><strong><b>Step 13: Check That It Works<\/b><\/strong><\/h3>\r\n<p class=\"wp-block-paragraph\">After a few minutes the load balancer appears in the list. Open the load balancer and look at its backend. When every machine shows as healthy, paste the load balancer address into a browser. If you used the hostname tip from Step 3, refresh several times and watch the page change between machines.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"439\" height=\"466\" class=\"wp-image-9182\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-502.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-502.png 439w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-502-283x300.png 283w\" sizes=\"auto, (max-width: 439px) 100vw, 439px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Give Load name for load balancing. Click Create.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"599\" height=\"482\" class=\"wp-image-9184\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-504.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-504.png 599w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-504-300x241.png 300w\" sizes=\"auto, (max-width: 599px) 100vw, 599px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">The Load balancer will be created<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9185\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-505.png\" alt=\"\" width=\"722\" height=\"265\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-505.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-505-300x110.png 300w\" sizes=\"auto, (max-width: 722px) 100vw, 722px\" \/><\/figure>\r\n<p>A new load balancer can take several minutes to start answering, so give it a little time before you assume something is wrong.<\/p>\r\n<h2><strong><b>Load Balancing Inside Google Kubernetes Engine<\/b><\/strong><\/h2>\r\n<p>Because this page lives in the Kubernetes section, here is how the same idea works in GKE. You do not click through the console. You describe what you want in Kubernetes and GKE builds the load balancer for you.<\/p>\r\n<ul>\r\n<li><b><\/b><strong><b>Service of type LoadBalancer.<\/b><\/strong>GKE creates a Google Cloud passthrough network load balancer in front of your Pods, and the Service gets an external IP address.<\/li>\r\n<li><b><\/b><b><\/b>For HTTP and HTTPS traffic with paths and hostnames, an Ingress creates an Application Load Balancer, the same family you built above.<\/li>\r\n<\/ul>\r\n<p>A minimal Service looks like this:<\/p>\r\n<p>apiVersion: v1<\/p>\r\n<p>kind: Service<\/p>\r\n<p>metadata:<\/p>\r\n<p>\u00a0\u00a0name: hello-lb<\/p>\r\n<p>spec:<\/p>\r\n<p>\u00a0\u00a0type: LoadBalancer<\/p>\r\n<p>\u00a0\u00a0selector:<\/p>\r\n<p>\u00a0\u00a0\u00a0\u00a0app: hello<\/p>\r\n<p>\u00a0\u00a0ports:<\/p>\r\n<p>\u00a0\u00a0&#8211; port: 80<\/p>\r\n<p>\u00a0\u00a0\u00a0\u00a0targetPort: 8080<\/p>\r\n<p>Apply it and wait for the external address:<\/p>\r\n<p>kubectl apply -f service.yaml<\/p>\r\n<p>kubectl get service hello-lb &#8211;watch<\/p>\r\n<p>Two settings are worth knowing. The Local value of externalTrafficPolicy keeps the real client IP address and sends traffic only to nodes that have a ready Pod. The Cluster value spreads traffic more evenly but hides the client address. For a private service, an annotation turns the Service into an internal load balancer.<\/p>\r\n<h2><strong><b>Common Mistakes to Avoid<\/b><\/strong><\/h2>\r\n<ul>\r\n<li><b><\/b><strong><b>Forgetting the health check firewall ranges.<\/b><\/strong>The backends show as unhealthy and users get errors.<\/li>\r\n<li><b><\/b><strong><b>Leaving out the named port.<\/b><\/strong>Without the http name on port 80, the backend service has nothing to send traffic to.<\/li>\r\n<li><b><\/b><strong><b>Expecting it to work instantly.<\/b><\/strong>New load balancers can take several minutes to start answering.<\/li>\r\n<li><b><\/b><strong><b>Opening the firewall to everyone for good.<\/b><\/strong>The wide open range is for a test. Narrow it for real workloads.<\/li>\r\n<li><b><\/b><strong><b>Copying commands with curly quotes or a long dash.<\/b><\/strong>Pasting from a web page can change characters in the startup script. Paste into a plain text editor first.<\/li>\r\n<li><b><\/b><strong><b>Forgetting to clean up.<\/b><\/strong>The load balancer, forwarding rule, instances and reserved addresses all bill until you remove them.<\/li>\r\n<\/ul>\r\n<p>You have now built a working HTTP load balancer with health checks and autoscaling. From here, try adding HTTPS with a certificate or put the same backend behind a GKE Ingress and compare how each feels to operate.<\/p>\r\n","protected":false},"excerpt":{"rendered":"<p>How to Set Up HTTP Load Balancing on Google Cloud Every website or application eventually hits the same problem. One server cannot handle all the traffic, and if that one server fails, everything goes down with it. A load balancer solves both problems. It sits in front of several identical servers, shares incoming requests between [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1,1639],"tags":[605,699,700,617,683,684,685,611,1400,692,1448,1449,1450,1451],"class_list":["post-9143","post","type-post","status-publish","format-standard","hentry","category-google-cloud-platform","category-kubernetes","tag-gcp","tag-gcp-certification","tag-gcp-cloud-console","tag-google-cloud","tag-google-cloud-certification","tag-google-cloud-console","tag-google-cloud-courses","tag-google-cloud-platform","tag-google-cloud-platform-tutorial","tag-google-cloud-training","tag-load-balancing","tag-load-balancing-concepts","tag-load-balancing-in-cloud-computing","tag-load-balancing-in-gcp"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.7 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Set Up HTTP Load Balancing on Google Cloud | PrwaTech<\/title>\n<meta name=\"description\" content=\"Build an HTTP load balancer on Google Cloud with an instance group, health check and backend service, and learn which load balancer type to use when.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Set Up HTTP Load Balancing on Google Cloud | PrwaTech\" \/>\n<meta property=\"og:description\" content=\"Build an HTTP load balancer on Google Cloud with an instance group, health check and backend service, and learn which load balancer type to use when.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/\" \/>\n<meta property=\"og:site_name\" content=\"Prwatech\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/prwatech.in\/\" \/>\n<meta property=\"article:published_time\" content=\"2026-10-10T13:34:35+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-10-11T13:26:49+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png\" \/>\n\t<meta property=\"og:image:width\" content=\"342\" \/>\n\t<meta property=\"og:image:height\" content=\"213\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Prwatech\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@Eduprwatech\" \/>\n<meta name=\"twitter:site\" content=\"@Eduprwatech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Prwatech\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"16 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/\",\"url\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/\",\"name\":\"How to Set Up HTTP Load Balancing on Google Cloud | PrwaTech\",\"isPartOf\":{\"@id\":\"https:\/\/prwatech.in\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png\",\"datePublished\":\"2026-10-10T13:34:35+00:00\",\"dateModified\":\"2026-10-11T13:26:49+00:00\",\"author\":{\"@id\":\"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3\"},\"description\":\"Build an HTTP load balancer on Google Cloud with an instance group, health check and backend service, and learn which load balancer type to use when.\",\"breadcrumb\":{\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#primaryimage\",\"url\":\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png\",\"contentUrl\":\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png\",\"width\":342,\"height\":213},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/prwatech.in\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Load Balancing\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/prwatech.in\/blog\/#website\",\"url\":\"https:\/\/prwatech.in\/blog\/\",\"name\":\"Prwatech\",\"description\":\"Share Ideas, Start Something Good.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/prwatech.in\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3\",\"name\":\"Prwatech\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/prwatech.in\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g\",\"caption\":\"Prwatech\"},\"url\":\"https:\/\/prwatech.in\/blog\/author\/prwatech123\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Set Up HTTP Load Balancing on Google Cloud | PrwaTech","description":"Build an HTTP load balancer on Google Cloud with an instance group, health check and backend service, and learn which load balancer type to use when.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/","og_locale":"en_US","og_type":"article","og_title":"How to Set Up HTTP Load Balancing on Google Cloud | PrwaTech","og_description":"Build an HTTP load balancer on Google Cloud with an instance group, health check and backend service, and learn which load balancer type to use when.","og_url":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/","og_site_name":"Prwatech","article_publisher":"https:\/\/www.facebook.com\/prwatech.in\/","article_published_time":"2026-10-10T13:34:35+00:00","article_modified_time":"2026-10-11T13:26:49+00:00","og_image":[{"width":342,"height":213,"url":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png","type":"image\/png"}],"author":"Prwatech","twitter_card":"summary_large_image","twitter_creator":"@Eduprwatech","twitter_site":"@Eduprwatech","twitter_misc":{"Written by":"Prwatech","Est. reading time":"16 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/","url":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/","name":"How to Set Up HTTP Load Balancing on Google Cloud | PrwaTech","isPartOf":{"@id":"https:\/\/prwatech.in\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#primaryimage"},"image":{"@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#primaryimage"},"thumbnailUrl":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png","datePublished":"2026-10-10T13:34:35+00:00","dateModified":"2026-10-11T13:26:49+00:00","author":{"@id":"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3"},"description":"Build an HTTP load balancer on Google Cloud with an instance group, health check and backend service, and learn which load balancer type to use when.","breadcrumb":{"@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#primaryimage","url":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png","contentUrl":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-467.png","width":342,"height":213},{"@type":"BreadcrumbList","@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/kubernetes\/load-balancing\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/prwatech.in\/blog\/"},{"@type":"ListItem","position":2,"name":"Load Balancing"}]},{"@type":"WebSite","@id":"https:\/\/prwatech.in\/blog\/#website","url":"https:\/\/prwatech.in\/blog\/","name":"Prwatech","description":"Share Ideas, Start Something Good.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/prwatech.in\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3","name":"Prwatech","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/prwatech.in\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g","caption":"Prwatech"},"url":"https:\/\/prwatech.in\/blog\/author\/prwatech123\/"}]}},"_links":{"self":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts\/9143","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/comments?post=9143"}],"version-history":[{"count":6,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts\/9143\/revisions"}],"predecessor-version":[{"id":11939,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts\/9143\/revisions\/11939"}],"wp:attachment":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/media?parent=9143"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/categories?post=9143"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/tags?post=9143"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}