{"id":703,"date":"2026-10-03T11:00:00","date_gmt":"2026-10-03T05:30:00","guid":{"rendered":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/"},"modified":"2026-11-29T01:29:46","modified_gmt":"2026-11-28T19:59:46","slug":"go-installation-windows-macos-linux","status":"publish","type":"post","link":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/","title":{"rendered":"Go Installation on Windows, macOS and Linux: Step by Step"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Go installation takes about five minutes on any computer, and it is the first step in our new Go programs series. In this post, you will install Go on Windows, macOS and Linux, check that it works, and run a small test program. After that, we will answer the most common interview questions about setup, with real programs and their output.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you are new to the language, first read <a href=\"https:\/\/smitabharat.com\/blog\/what-is-go-lang\/\">what Go is and why teams use it<\/a>. We also have a short <a href=\"https:\/\/smitabharat.com\/blog\/install-go-first-program\/\">first program guide<\/a> from the tutorial series. This post goes further, because it covers every operating system, the Go environment variables and the setup questions that interviewers like to ask.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What is Go Installation?<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Go installation means putting the Go toolchain on your computer. The toolchain is one download that holds the compiler, the standard library and the <code>go<\/code> command. With it, you can build, run, test and format Go code.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Think of it like setting up a kitchen. The compiler is the stove, the standard library is the pantry, and the <code>go<\/code> command is the chef who uses both. Once the kitchen is ready, you can cook any recipe.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Why a Clean Go Installation Matters<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A clean setup saves you hours later. Most Go installation errors, such as &#8220;go is not recognized&#8221;, come from a broken PATH and not from the code. So it is worth doing this step carefully once.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Interviews:<\/strong> many Go interviews start with setup questions such as &#8220;What is GOPATH?&#8221; or &#8220;Where does go install put binaries?&#8221;.<\/li>\n\n\n<li><strong>Team work:<\/strong> when everyone uses a supported Go version, builds behave the same on every laptop.<\/li>\n\n\n<li><strong>Tools:<\/strong> editors like VS Code need a working <code>go<\/code> command to give you autocomplete and error hints.<\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">How Go Installation Works<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Every Go installation follows the same four steps, whatever your operating system is. First, you download the right package from the official site. Next, you run the installer or extract the archive. Then, you make sure the <code>go\/bin<\/code> folder is on your PATH. Finally, you open a new terminal and run <code>go version<\/code>.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><a href=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"640\" src=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1-1024x640.png\" alt=\"Go installation diagram showing the four steps from download to go version\" class=\"wp-image-692\" srcset=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1-1024x640.png 1024w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1-300x188.png 300w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1-768x480.png 768w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1-1536x960.png 1536w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-1-2048x1280.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">The four steps of Go installation are the same on Windows, macOS and Linux.<\/figcaption><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The table below shows what the official installer puts on each system by default.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>System<\/th><th>Package type<\/th><th>Default folder<\/th><th>PATH added<\/th><\/tr><\/thead><tbody><tr><td>Windows<\/td><td>.msi installer<\/td><td>C:\\Program Files\\Go<\/td><td>Yes, automatically<\/td><\/tr><tr><td>macOS<\/td><td>.pkg installer<\/td><td>\/usr\/local\/go<\/td><td>Yes, automatically<\/td><\/tr><tr><td>Linux<\/td><td>.tar.gz archive<\/td><td>\/usr\/local\/go<\/td><td>No, you add it<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Go Installation on Windows<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Windows has the easiest setup, because the installer does almost everything for you.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Open <a href=\"https:\/\/go.dev\/dl\/\">the official Go download page<\/a> and pick the Windows .msi file for your system (usually amd64).<\/li>\n\n\n<li>Double-click the file and follow the steps. Keep the default folder unless you have a good reason to change it.<\/li>\n\n\n<li>Close every open Command Prompt or PowerShell window. Old windows still use the old PATH.<\/li>\n\n\n<li>Open a new terminal and run the version command shown below.<\/li>\n\n<\/ol>\n\n\n\n<pre class=\"wp-block-code\"><code>go version<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You should see a line like this one. Your version number may be newer.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>go version go1.27.2 windows\/amd64<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Install Go with winget<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">If you like the command line, Windows Package Manager can do the same job in one step.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>winget install --id GoLang.Go<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Go Installation on macOS<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">On a Mac, you can use the official .pkg file or Homebrew. Both work well, so pick one and stay with it.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Option 1: the official .pkg file<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Download the macOS package from go.dev\/dl. Choose ARM64 for Apple chips (M1 and later) and x86-64 for older Intel Macs. Then open the file and click through the installer. It puts Go in \/usr\/local\/go and adds \/usr\/local\/go\/bin to your PATH.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Option 2: Homebrew<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Homebrew is a popular package manager for macOS. If you already use it, this one command installs Go.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>brew install go\ngo version<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The output looks like this on an Apple chip Mac.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>go version go1.27.2 darwin\/arm64<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Go Installation on Linux<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A Linux Go installation means you extract an archive and set PATH yourself. It sounds harder, but it is only three commands. First, remove any old copy in \/usr\/local\/go, because mixing two versions in one folder breaks Go.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># replace the file name with the version you downloaded\nsudo rm -rf \/usr\/local\/go\nsudo tar -C \/usr\/local -xzf go1.27.2.linux-amd64.tar.gz\n\n# add Go to PATH for your user\necho 'export PATH=$PATH:\/usr\/local\/go\/bin:$HOME\/go\/bin' &gt;&gt; ~\/.profile\nsource ~\/.profile\ngo version<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Here is what each part does. The <code>tar -C \/usr\/local<\/code> part extracts Go into \/usr\/local\/go. The <code>export PATH<\/code> line lets your shell find the <code>go<\/code> command. We also add <code>$HOME\/go\/bin<\/code>, so tools you install later work right away.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>go version go1.27.2 linux\/amd64<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Why not apt install golang?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">You can install Go with your distro&#8217;s package manager. However, these packages are often a few versions behind. For learning and for jobs, the official archive is the safer choice, because you always get the latest stable release.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Check Your Go Installation with go env<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The <code>go env<\/code> command prints the settings the <code>go<\/code> command uses. It is the best tool to debug any Go installation problem. You can print all values, or just the ones you care about.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>go env GOROOT GOPATH GOOS GOARCH GOBIN<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">On a Linux laptop, the output looks like this. GOBIN is empty, which is normal.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/usr\/local\/go\n\/home\/asha\/go\nlinux\namd64\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The table below explains the most common Go environment variables.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>Variable<\/th><th>What it means<\/th><th>Default value<\/th><\/tr><\/thead><tbody><tr><td>GOROOT<\/td><td>Where Go itself is installed<\/td><td>Install folder, like \/usr\/local\/go<\/td><\/tr><tr><td>GOPATH<\/td><td>Your workspace for module cache and tools<\/td><td>$HOME\/go<\/td><\/tr><tr><td>GOBIN<\/td><td>Where go install puts programs<\/td><td>Empty, so $GOPATH\/bin is used<\/td><\/tr><tr><td>GOOS<\/td><td>Target operating system<\/td><td>Your current OS<\/td><\/tr><tr><td>GOARCH<\/td><td>Target CPU type<\/td><td>Your current CPU<\/td><\/tr><tr><td>GOPROXY<\/td><td>Where modules are downloaded from<\/td><td>proxy.golang.org<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">To change a value for good, use <code>go env -w<\/code>. For example, <code>go env -w GOBIN=$HOME\/bin<\/code> sets a new folder for installed tools. To undo it, run <code>go env -u GOBIN<\/code>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Go Installation Test Program<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Now let&#8217;s prove that everything works with a real program. Create a folder named <code>hello-setup<\/code>, then create the module and the file.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mkdir hello-setup\ncd hello-setup\ngo mod init example.com\/hello-setup<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Step 1: A Tiny Go Installation Check<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Put this code in a file named <code>main.go<\/code>. It is the smallest useful program, and it only prints two lines.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>package main \/\/ every runnable Go program starts with package main\n\nimport \"fmt\" \/\/ fmt is the standard package for printing\n\n\/\/ main is where the program starts\nfunc main() {\n    fmt.Println(\"Hello, Go!\")\n\n    \/\/ Go works out 2 + 3 first, then prints the answer\n    fmt.Println(\"2 + 3 =\", 2+3)\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Run it with this command from inside the folder.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>go run .<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You should see these two lines.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Hello, Go!\n2 + 3 = 5<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The <code>go run .<\/code> command compiles every file in the folder and runs it. <code>fmt.Println<\/code> prints its values with a space between them. If you see both lines, the compiler and the <code>go<\/code> command both work.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 2: Print Facts About Your Go Installation<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Now replace the code in <code>main.go<\/code> with this version. It prints a greeting and some facts about your setup.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>package main\n\n\/\/ We import two packages, so we put them inside ( )\nimport (\n    \"fmt\"\n    \"runtime\" \/\/ runtime gives facts about the running program\n)\n\n\/\/ main prints a greeting and four facts about this computer\nfunc main() {\n    fmt.Println(\"Hello, Go! Your setup works.\")\n\n    fmt.Println(\"Go version:\", runtime.Version()) \/\/ the Go release that built this program\n    fmt.Println(\"OS:\", runtime.GOOS)              \/\/ operating system, like linux or windows\n    fmt.Println(\"CPU type:\", runtime.GOARCH)      \/\/ CPU family, like amd64 or arm64\n    fmt.Println(\"CPU cores:\", runtime.NumCPU())   \/\/ how many CPU cores Go can see\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Run it again with <code>go run .<\/code> from the same folder.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here is the output on a Linux laptop with 8 cores. Your values will match your own machine.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Hello, Go! Your setup works.\nGo version: go1.27.2\nOS: linux\nCPU type: amd64\nCPU cores: 8<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">In short, <code>package main<\/code> and <code>func main()<\/code> mark this file as a program. The <code>runtime<\/code> package tells us which Go version built it and where it runs. If you see this output, your Go installation is complete.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Set Up VS Code for Go<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">You can write Go in any editor once your Go installation works. Still, most beginners use VS Code, because the free Go extension is very good.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Install VS Code from its official site.<\/li>\n\n\n<li>Open the Extensions panel and install the extension named &#8220;Go&#8221; by the Go team at Google.<\/li>\n\n\n<li>Open your <code>hello-setup<\/code> folder. When VS Code asks to install Go tools such as gopls, click Install All.<\/li>\n\n\n<li>Save <code>main.go<\/code>. The extension formats it and shows errors as you type.<\/li>\n\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\">Go Installation vs Online Compiler<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Some beginners skip setup and use a browser tool instead. The comparison below shows when each one makes sense.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><a href=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"640\" src=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2-1024x640.png\" alt=\"Go installation vs online compiler comparison diagram\" class=\"wp-image-693\" srcset=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2-1024x640.png 1024w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2-300x188.png 300w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2-768x480.png 768w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2-1536x960.png 1536w, https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-diagram-2-2048x1280.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">A local Go installation gives full control, while an online compiler is best for quick tests.<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>Feature<\/th><th>Local Go installation<\/th><th>Online Go compiler<\/th><\/tr><\/thead><tbody><tr><td>Setup time<\/td><td>About five minutes<\/td><td>None<\/td><\/tr><tr><td>Works offline<\/td><td>Yes<\/td><td>No<\/td><\/tr><tr><td>File and network access<\/td><td>Full access<\/td><td>Blocked or limited<\/td><\/tr><tr><td>Third-party packages<\/td><td>Any package<\/td><td>Limited<\/td><\/tr><tr><td>Real projects<\/td><td>Yes<\/td><td>Not practical<\/td><\/tr><tr><td>Sharing a snippet<\/td><td>Needs Git or a gist<\/td><td>One share link<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">So, install Go locally for real learning and projects. Use an online tool when you want to test a tiny idea or share code with a friend. We list the best online options in a later post of this series.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Common Go Installation Mistakes<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Old terminal window:<\/strong> the PATH change only applies to new windows. Close and reopen your terminal after you install Go.<\/li>\n\n\n<li><strong>Two Go versions in one folder:<\/strong> on Linux, always delete \/usr\/local\/go before you extract a new archive.<\/li>\n\n\n<li><strong>Wrong CPU file:<\/strong> an ARM Mac needs the arm64 file, and most Windows PCs need amd64.<\/li>\n\n\n<li><strong>Setting GOROOT by hand:<\/strong> modern Go finds GOROOT by itself. A wrong manual value causes strange errors.<\/li>\n\n\n<li><strong>Code inside GOROOT:<\/strong> never save your projects in the Go install folder. Use any normal folder with <code>go mod init<\/code>.<\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Best Practices After Go Installation<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Use the latest stable version.<\/strong> The Go team supports only the two newest releases with security fixes.<\/li>\n\n\n<li><strong>Run go version and go env first<\/strong> whenever something breaks, because they show the real setup.<\/li>\n\n\n<li><strong>Add $HOME\/go\/bin to PATH<\/strong>, so tools you install with <code>go install<\/code> run from anywhere.<\/li>\n\n\n<li><strong>Use modules for every project<\/strong>, so you can keep code in any folder you like.<\/li>\n\n\n<li><strong>Update the same way you installed.<\/strong> If you used Homebrew, update with <code>brew upgrade go<\/code>.<\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Go Installation Interview Questions and Answers<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">These Go installation questions come up often in interviews. Many answers include a small program, so you can run it and see the output yourself.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Go Installation Basics Questions<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q1. How do you check which Go version is installed?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Run <code>go version<\/code> in a terminal. It prints the version, the OS and the CPU type, for example <code>go version go1.27.2 linux\/amd64<\/code>. Inside a program, you can call <code>runtime.Version()<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q2. What is GOROOT?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">GOROOT is the folder where Go itself lives, such as \/usr\/local\/go. It holds the compiler and the standard library source. You almost never need to set it, because the <code>go<\/code> command finds it on its own.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q3. What is GOPATH, and is it still needed?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">GOPATH is your Go workspace, by default <code>$HOME\/go<\/code>. Before modules, all code had to live inside it. Today, modules let you work in any folder. Still, GOPATH holds the module cache in <code>pkg\/mod<\/code> and installed tools in <code>bin<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q4. What is the difference between GOROOT and GOPATH?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">GOROOT holds Go&#8217;s own files, and GOPATH holds your downloaded modules and tools. In short, GOROOT belongs to Go, while GOPATH belongs to you.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Go Environment Variable Questions<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q5. Why does this program print an empty GOPATH?<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>package main\n\nimport (\n    \"fmt\"\n    \"os\"\n)\n\n\/\/ main reads the GOPATH variable straight from the system\nfunc main() {\n    \/\/ os.Getenv returns \"\" when the variable is not set\n    gopath := os.Getenv(\"GOPATH\")\n\n    \/\/ %q prints the text inside double quotes, so an empty value shows as \"\"\n    fmt.Printf(\"GOPATH = %q\\n\", gopath)\n}<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>GOPATH = \"\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The program reads the real environment variable, and most people never set it. The <code>go<\/code> command uses a default of <code>$HOME\/go<\/code> when it is missing. So <code>go env GOPATH<\/code> shows a path, but <code>os.Getenv<\/code> shows an empty string.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q6. Where does go install put the binary?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It puts it in GOBIN if that is set. Otherwise, it uses <code>$GOPATH\/bin<\/code>, which is usually <code>$HOME\/go\/bin<\/code>. That is why you add this folder to PATH.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q7. You get &#8220;go: command not found&#8221; or &#8220;&#8216;go&#8217; is not recognized&#8221;. What do you check?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">First, open a new terminal, because old windows keep the old PATH. Then check that the Go bin folder, such as \/usr\/local\/go\/bin, is on PATH. On Windows, run <code>where go<\/code>, and on macOS or Linux, run <code>which go<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q8. What does go env -w do?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It saves a Go setting in your user config file, so it stays after you close the terminal. For example, <code>go env -w GOPROXY=https:\/\/proxy.golang.org,direct<\/code>. You can remove it again with <code>go env -u GOPROXY<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q9. How do you print the OS and CPU type from a program?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Use the <code>runtime<\/code> package. The values are fixed when the program is built.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>package main\n\nimport (\n    \"fmt\"\n    \"runtime\"\n)\n\n\/\/ main prints the system this program was built for\nfunc main() {\n    system := runtime.GOOS \/\/ operating system, like linux\n    cpu := runtime.GOARCH  \/\/ CPU type, like amd64\n\n    \/\/ + joins strings together\n    fmt.Println(system + \"\/\" + cpu)\n}<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>linux\/amd64<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>runtime.GOOS<\/code> and <code>runtime.GOARCH<\/code> are plain strings. The program joins them with a slash and prints the result.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q10. What are GOOS and GOARCH used for?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">They choose the target system for a build. For example, <code>GOOS=windows GOARCH=amd64 go build<\/code> makes a Windows .exe on a Linux machine. Our <a href=\"https:\/\/smitabharat.com\/blog\/go-cross-compilation-build\/\">Go cross compilation guide<\/a> covers this in detail.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Go Version and Toolchain Questions<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q11. How can you keep two Go versions on one machine?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Install the extra version as a separate command. For example, run <code>go install golang.org\/dl\/go1.26.0@latest<\/code>, then <code>go1.26.0 download<\/code>. After that, <code>go1.26.0 version<\/code> uses the old release, and <code>go<\/code> still uses your main one.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q12. What is GOTOOLCHAIN?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It controls which Go toolchain runs your build. If a module&#8217;s go.mod says it needs a newer Go, the <code>go<\/code> command can download that toolchain for you. Setting <code>GOTOOLCHAIN=local<\/code> turns this off and always uses the installed version.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q13. How do you update Go?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Use the same method you used to install it. On Windows and macOS, run the new installer. On Linux, delete \/usr\/local\/go and extract the new archive. With Homebrew, run <code>brew upgrade go<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q14. How do you uninstall Go?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Delete the Go install folder and remove it from PATH. On Windows, use &#8220;Add or remove programs&#8221;. You can also delete <code>$HOME\/go<\/code> if you no longer need the module cache and tools.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Program Output Questions<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q15. What does this program print, and why?<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>package main\n\nimport \"fmt\"\n\n\/\/ main prints a word and the result of a comparison\nfunc main() {\n    \/\/ 1+1 == 2 asks a yes or no question, so its value is true or false\n    fmt.Println(\"Go\", 1+1 == 2)\n}<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>Go true<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>Println<\/code> puts a space between values and adds a new line at the end. The expression <code>1+1 == 2<\/code> is a bool, so it prints <code>true<\/code>. Interviewers use tiny programs like this to check basic output rules.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q16. Why must every program have package main and func main?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The <code>go<\/code> command only builds a runnable program from <code>package main<\/code>. Inside it, <code>func main()<\/code> is the entry point where the program starts. Without both, you get a library package and not a program.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q17. What happens if you name the package something else?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><code>go run<\/code> fails with an error. For example, with <code>package hello<\/code>, Go says the package is not a main package. The fix is to change it back to <code>package main<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q18. How many CPU cores can a Go program use by default?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">By default, Go can use all logical cores, and <code>runtime.NumCPU()<\/code> reports how many there are. You can limit it with the GOMAXPROCS environment variable. This matters later when we cover goroutines.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Module and Proxy Questions<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q19. What is GOPROXY, and why does it matter?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">GOPROXY is the server that <code>go<\/code> uses to download modules. The default is proxy.golang.org, which is fast and caches public modules. Companies often set their own proxy for private code.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q20. Do you need to set GO111MODULE today?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">No. Module mode has been the default for years, so you can leave GO111MODULE unset. You only see it in very old tutorials.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q21. Where is the module cache stored?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It lives in <code>$GOPATH\/pkg\/mod<\/code>. You can print the exact folder with <code>go env GOMODCACHE<\/code>, and clear it with <code>go clean -modcache<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Q22. How do you verify the download is safe?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The download page lists a SHA256 checksum for each file. You can compare it with <code>sha256sum<\/code> on Linux or <code>shasum -a 256<\/code> on macOS. Installers from go.dev are also signed.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Practice Task<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Install Go on your machine, then change the test program so it also prints the number of goroutines with <code>runtime.NumGoroutine()<\/code>. Hint: a plain program starts with exactly one goroutine, the one running <code>main<\/code>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Official Resources<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/go.dev\/doc\/install\">Download and install Go (official guide)<\/a><\/li>\n\n\n<li><a href=\"https:\/\/go.dev\/dl\/\">All Go downloads<\/a><\/li>\n\n\n<li><a href=\"https:\/\/go.dev\/doc\/manage-install\">Managing Go installations<\/a><\/li>\n\n\n<li><a href=\"https:\/\/pkg.go.dev\/runtime\">runtime package documentation<\/a><\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Quick Recap<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Go installation puts the compiler, standard library and the <code>go<\/code> command on your computer.<\/li>\n\n\n<li>Windows and macOS installers set PATH for you, but on Linux you add \/usr\/local\/go\/bin yourself.<\/li>\n\n\n<li><code>go version<\/code> and <code>go env<\/code> are the first commands to run when something breaks.<\/li>\n\n\n<li>GOROOT is where Go lives, and GOPATH holds your module cache and tools.<\/li>\n\n\n<li>A small program with the <code>runtime<\/code> package proves the setup works.<\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">What&#8217;s Next?<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Your setup is ready, so next we learn every way to run code. Read <a href=\"https:\/\/smitabharat.com\/blog\/how-to-run-a-go-program\/\">how to run a Go program with go run, go build and go install<\/a>. When you want more setup practice for interviews, try the <a href=\"https:\/\/smitabharat.com\/blog\/go-basics-interview-questions-part-1\/\">Go basics interview questions<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Go installation takes about five minutes on any computer, and it is the first step in our new Go programs series. In this post,&hellip;<\/p>\n","protected":false},"author":1,"featured_media":691,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_swapz_level":"","_swapz_series_part":0,"_swapz_hide_toc":false,"_swapz_hide_featured":false,"_swapz_description":"","footnotes":""},"categories":[106],"tags":[96,22,11,104,21],"swapz_series":[],"class_list":["post-703","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-go-programs","tag-beginner","tag-go-installation","tag-go-lang","tag-go-programs","tag-golang-basics"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.9 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Go Installation on Windows, macOS and Linux<\/title>\n<meta name=\"description\" content=\"Go installation guide for Windows, macOS and Linux: set PATH, check go env, run a test program and practise setup interview questions.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Go Installation on Windows, macOS and Linux\" \/>\n<meta property=\"og:description\" content=\"Go installation guide for Windows, macOS and Linux: set PATH, check go env, run a test program and practise setup interview questions.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/\" \/>\n<meta property=\"og:site_name\" content=\"Smita Bharat - Blog\" \/>\n<meta property=\"article:published_time\" content=\"2026-10-03T05:30:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-11-28T19:59:46+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-featured.png\" \/>\n\t<meta property=\"og:image:width\" content=\"2400\" \/>\n\t<meta property=\"og:image:height\" content=\"1260\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Smita\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Smita\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"15 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/\"},\"author\":{\"name\":\"Smita\",\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#\\\/schema\\\/person\\\/27a1b1067d396703215c54acedbfd339\"},\"headline\":\"Go Installation on Windows, macOS and Linux: Step by Step\",\"datePublished\":\"2026-10-03T05:30:00+00:00\",\"dateModified\":\"2026-11-28T19:59:46+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/\"},\"wordCount\":2498,\"publisher\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#\\\/schema\\\/person\\\/27a1b1067d396703215c54acedbfd339\"},\"image\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/10\\\/go-installation-windows-macos-linux-featured.png\",\"keywords\":[\"Beginner\",\"Go Installation\",\"Go Lang\",\"Go Programs\",\"Golang Basics\"],\"articleSection\":[\"Go Programs\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/\",\"url\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/\",\"name\":\"Go Installation on Windows, macOS and Linux\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/10\\\/go-installation-windows-macos-linux-featured.png\",\"datePublished\":\"2026-10-03T05:30:00+00:00\",\"dateModified\":\"2026-11-28T19:59:46+00:00\",\"description\":\"Go installation guide for Windows, macOS and Linux: set PATH, check go env, run a test program and practise setup interview questions.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#primaryimage\",\"url\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/10\\\/go-installation-windows-macos-linux-featured.png\",\"contentUrl\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/10\\\/go-installation-windows-macos-linux-featured.png\",\"width\":2400,\"height\":1260,\"caption\":\"Go installation featured image: setup steps for Windows, macOS and Linux\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/go-installation-windows-macos-linux\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Go Installation on Windows, macOS and Linux: Step by Step\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/\",\"name\":\"Smita Bharat Blog\",\"description\":\"Golang &amp; Backend Development Tutorials and Interview Questions\",\"publisher\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#\\\/schema\\\/person\\\/27a1b1067d396703215c54acedbfd339\"},\"alternateName\":\"Smita Bharat\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#\\\/schema\\\/person\\\/27a1b1067d396703215c54acedbfd339\",\"name\":\"Smita\",\"logo\":{\"@id\":\"https:\\\/\\\/smitabharat.com\\\/blog\\\/#\\\/schema\\\/person\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/smitabharat.com\\\/blog\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Go Installation on Windows, macOS and Linux","description":"Go installation guide for Windows, macOS and Linux: set PATH, check go env, run a test program and practise setup interview questions.","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:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/","og_locale":"en_US","og_type":"article","og_title":"Go Installation on Windows, macOS and Linux","og_description":"Go installation guide for Windows, macOS and Linux: set PATH, check go env, run a test program and practise setup interview questions.","og_url":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/","og_site_name":"Smita Bharat - Blog","article_published_time":"2026-10-03T05:30:00+00:00","article_modified_time":"2026-11-28T19:59:46+00:00","og_image":[{"width":2400,"height":1260,"url":"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-featured.png","type":"image\/png"}],"author":"Smita","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Smita","Est. reading time":"15 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#article","isPartOf":{"@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/"},"author":{"name":"Smita","@id":"https:\/\/smitabharat.com\/blog\/#\/schema\/person\/27a1b1067d396703215c54acedbfd339"},"headline":"Go Installation on Windows, macOS and Linux: Step by Step","datePublished":"2026-10-03T05:30:00+00:00","dateModified":"2026-11-28T19:59:46+00:00","mainEntityOfPage":{"@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/"},"wordCount":2498,"publisher":{"@id":"https:\/\/smitabharat.com\/blog\/#\/schema\/person\/27a1b1067d396703215c54acedbfd339"},"image":{"@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#primaryimage"},"thumbnailUrl":"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-featured.png","keywords":["Beginner","Go Installation","Go Lang","Go Programs","Golang Basics"],"articleSection":["Go Programs"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/","url":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/","name":"Go Installation on Windows, macOS and Linux","isPartOf":{"@id":"https:\/\/smitabharat.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#primaryimage"},"image":{"@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#primaryimage"},"thumbnailUrl":"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-featured.png","datePublished":"2026-10-03T05:30:00+00:00","dateModified":"2026-11-28T19:59:46+00:00","description":"Go installation guide for Windows, macOS and Linux: set PATH, check go env, run a test program and practise setup interview questions.","breadcrumb":{"@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#primaryimage","url":"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-featured.png","contentUrl":"https:\/\/smitabharat.com\/blog\/wp-content\/uploads\/2026\/10\/go-installation-windows-macos-linux-featured.png","width":2400,"height":1260,"caption":"Go installation featured image: setup steps for Windows, macOS and Linux"},{"@type":"BreadcrumbList","@id":"https:\/\/smitabharat.com\/blog\/go-installation-windows-macos-linux\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/smitabharat.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Go Installation on Windows, macOS and Linux: Step by Step"}]},{"@type":"WebSite","@id":"https:\/\/smitabharat.com\/blog\/#website","url":"https:\/\/smitabharat.com\/blog\/","name":"Smita Bharat Blog","description":"Golang &amp; Backend Development Tutorials and Interview Questions","publisher":{"@id":"https:\/\/smitabharat.com\/blog\/#\/schema\/person\/27a1b1067d396703215c54acedbfd339"},"alternateName":"Smita Bharat","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/smitabharat.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/smitabharat.com\/blog\/#\/schema\/person\/27a1b1067d396703215c54acedbfd339","name":"Smita","logo":{"@id":"https:\/\/smitabharat.com\/blog\/#\/schema\/person\/image\/"},"sameAs":["https:\/\/smitabharat.com\/blog"]}]}},"_links":{"self":[{"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/posts\/703","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/comments?post=703"}],"version-history":[{"count":2,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/posts\/703\/revisions"}],"predecessor-version":[{"id":865,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/posts\/703\/revisions\/865"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/media\/691"}],"wp:attachment":[{"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/media?parent=703"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/categories?post=703"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/tags?post=703"},{"taxonomy":"swapz_series","embeddable":true,"href":"https:\/\/smitabharat.com\/blog\/wp-json\/wp\/v2\/swapz_series?post=703"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}