How To Install Go on Debian 10

Install Go on Debian 10

In this tutorial, we will show you how to install Go on Debian 10. For those of you who didn’t know, Go is a modern open-source programming language created by Google, used to build reliable, simple, fast, and efficient software. Some popular applications that are written in Go are Docker, Kubernetes, Dropbox, Openshift, Netflix, Golang.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you through the step-by-step installation of the Go open-source programming language on a Debian 10 (Buster).


  • A server running one of the following operating systems: Debian 10 (Buster).
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install Go on Debian 10 Buster

Step 1. Before running the tutorial below, it’s important to make sure your system is up to date by running the following apt commands in the terminal:

sudo apt update

Step 2. Installing Go on Debian 10.

Now we go to Go’s download page and grab a link for the latest version:


Next, extract the tar archive to the /usr/local directory:

sudo tar -C /usr/local -xzf go1.16.linux-amd64.tar.gz

Then, set the path environment variable in order to find Go executable binaries by the system. For that, we need to open /.bash_profile using the below command:

sudo nano ~/.bash_profile

Add the below lines:

export PATH=$PATH:/usr/local/go/bin:$GOPATH/bin

Save and close the file. After that run the below command to reload the running profile:

source ~/.bash_profile

Here comes the easy bit, let’s check our installed go version:

$ go version
go version go1.16.3 linux/amd64

Congratulations! You have successfully installed Go (Golang). Thanks for using this tutorial for installing the latest version of the Golang open-source programming language on the Debian system. For additional help or useful information, we recommend you check the official Go website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!
Back to top button