Install Go on Windows 11

Installer options

Windows 11 gives you two simple paths: the winget package manager and the classic MSI installer from the official download page.

Both install the same toolchain, so pick winget for speed and MSI when you want a guided setup window.

Install with winget

Open Windows Terminal or PowerShell and run the installer command below.

winget install -e --id GoLang.Go

Prefer clicks to commands. Then grab the MSI file from the official download page, run it, and accept the defaults.

Close and reopen the terminal after either method so the new PATH value is loaded.

go version

A fresh install should answer with its version number.

go version

go version go1.21 windows/amd64

If the command is not found, reopen the terminal once more and check the next section about PATH.

GOPATH and PATH

The installer adds the Go binary folder to user PATH and sets a default workspace for modules and tools.

go env GOPATH

C:\Users\user\go

go env GOROOT

C:\Program Files\Go

Leave the defaults while learning, and only edit system environment variables when you need a custom workspace location.

Next: Install Go on Ubuntu

Article author: Arthur Isaev