Installing Go
Download the official installer for your operating system from go.dev/dl. This course targets Go 1.23 — any newer 1.x release works too, since Go 1 guarantees backward compatibility.
- Windows — run the
.msiinstaller; it adds Go to yourPATH. - macOS — run the
.pkginstaller, orbrew install go. - Linux — extract the archive into
/usr/localand add/usr/local/go/binto yourPATH:
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf go1.23.4.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
Open a new terminal and check the installation:
go version
go version go1.23.4 linux/amd64
The exact version number and platform will match what you
installed. If the terminal says go: command not found (or "is
not recognized" on Windows), the go/bin directory isn't on
your PATH yet — reopening the terminal usually fixes it.