2 Ways to install VS code on Debian 11 Bullseye Linux

Learn the simple way to install Microsoft Visual Studio Code on Debian 11 Bullseye or 10 Buster using command terminal.

Microsoft’s “Visual Studio Code”  is a free and open-source code editor available to install on popular operating systems. It also contains many useful functions for developers. Although the tool comes from Microsoft, it is also available for Mac OS and Linux, which makes the cross-system development of applications in teams much easier.

Microsoft promises that applications with ASP.NET Framework and Node applications, in particular, should be able to be created very quickly on VS code. And that is the reason Visual Studio code comes with built-in debugging support for the Node.js runtime environment. Developers can debug JavaScript, TypeScript, and any other language based on JavaScript in VS Code without the need for an additional tool.

Also, website creation with HTML, CSS, JSON, LESS, SASS, PHP JavaScript, and other technologies is very easy. Your project can be created as a Git repository. To make the coder’s life easier, VSCode has integrated some convenience functions, such as syntax color coding, auto-completion of code, and bracket matching.

Well, you would already know about this Coding platform, hence, let’s talk about the main topic of this article that is the simple way to install VS Code on the latest Debian 11 or 10 desktop Linux distro.

Steps to install Visual Studio Code on Debian 11 or 10

The steps given here are also applicable for Kali Linux, Ubuntu, Linux Mint, Elementary OS, MX Linux, POP!OS and others.

#1st Way using repo:

Add Microsoft Visual Studio Code GPG Key

We need to add a key that has been used to sign the packages of this coding platform. Otherwise, the system will not accept the VSCode repository to download the required packages.

curl -sSL https://packages.microsoft.com/keys/microsoft.asc -o microsoft.asc
gpg --no-default-keyring --keyring ./ms_vscode_key_temp.gpg --import ./microsoft.asc
gpg --no-default-keyring --keyring ./ms_vscode_key_temp.gpg --export > ./ms_vscode_key.gpg
sudo mv ms_vscode_key.gpg /etc/apt/trusted.gpg.d/


Add VS Code Repository on Debian 11

The next thing is to add the repo manually of this code editor on your Debian OS, using the command given below:

echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" | sudo tee /etc/apt/sources.list.d/vscode.list


Run system update

To ensure that the system could recognize the newly added repo packages, run the system update command once:

sudo apt update


Comand to install Visual Studio Code

finally, run a single command to get the packages on your Debina system to install VS Code:

sudo apt install code


Uninstallation (optional)

Well, there is always a point when you don’t require any installed application, and if the same goes for VSCode then here are the commands to completely remove it.

sudo apt remove code
sudo rm /etc/apt/sources.list.d/vscode.*
sudo rm /etc/apt/trusted.gpg.d/ms_vscode_key.gpg

2nd Method using Deb binary file directly

Open browser in Debian

Go to your Debian Linux system and open whatever browser you have. However, the default one is Firefox.


Download the VS Code Debian Package

The next step is to visit the official webpage of VS code to download the package available to install on Debian and its based Linux systems. Here is the link to the download page.

Download VS code for Debian Linux


Switch to Downloads

First, open the Command Terminal. If you have used the browser to download the Visual Studio code Debian file, then switch to “Downloads“. It is because the file we get from the browser goes automatically into that.

cd Downloads


Install Visual code Studio on Debian 11 or 10

Now, we can either use the APT package manager or DPKG tool to install the downloaded .deb file of VS Code. To do that, simply run the below-given command.

sudo apt install ./file-name.deb

Replace file-name. deb with the actual name of the file you have downloaded.

sudo apt install ./code_*_amd64.deb



Run the Code Editor

Go to All Applications, search for VScode and when its icon appears, click to run the same.

Simple Way to insall VS code on Debian 11 Linux


Uninstall or Remove

Those who don’t require Visual Studio Code anymore on their Debian Linux can remove it using the command:

sudo apt remove code


Other Articles:




Comments (2)

  1. Me November 10, 2021
    • Heyan November 11, 2021

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.