Skip to content
TrySitePrice

How To Install Microsoft Visual Studio Code on Linux

Best/Tutorial

Microsoft Visual Studio Code (VSCode) can be installed on Linux systems in several ways. Here's how to install it on a Debian-based system like Ubuntu:

  1. Download the DEB package for your architecture (32-bit or 64-bit) from the Visual Studio Code website: https://code.visualstudio.com/download
  2. Open a terminal window and navigate to the directory where the DEB package is located.
  3. Run the following command to install the DEB package:

sudo dpkg -i <package_name>.deb

Replace <package_name> with the actual name of the DEB package you downloaded.

  1. If there are any missing dependencies, run the following command to install them:

sudo apt-get install -f

  1. Finally, you can start Visual Studio Code by running the following command:

code

If you prefer to install Visual Studio Code using the apt repository, you can add the Microsoft package repository to your system and install it using the apt-get command. Here's how:

  1. Open a terminal window and run the following command to add the Microsoft package repository:

wget -q https://packages.microsoft.com/keys/microsoft.asc -O- | sudo apt-key add -

  1. Add the repository to your sources list by running the following command:

sudo add-apt-repository "deb https://packages.microsoft.com/repos/vscode stable main"

  1. Update the package information on your system by running the following command:

sudo apt-get update

  1. Finally, run the following command to install Visual Studio Code:

sudo apt-get install code

After installation, you can start Visual Studio Code from the application menu or by running the code command in a terminal window.