Visual Studio Code Silent Install (How-To Guide)

Visual Studio Code is an IDE developed by Microsoft. This article will serve as an informative guide and give you a clear understanding of how to perform a silent installation of Visual Studio Code from the command line using the EXE installer.

How to Install Visual Studio Code Silently

Microsoft Visual Studio Code 32-bit Silent Install (EXE)

  1. Navigate to: https://code.visualstudio.com/download
  2. Select the 32-bit System Installer
  3. Download the VSCodeSetup-ia32-x.y.z.exe to a folder created at (C:\Downloads)
  4. Open an Elevated Command Prompt by Right-Clicking on Command Prompt and select Run as Administrator
  5. Navigate to the C:\Downloads folder
  6. Enter the following command:
    • VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode
  7. Press Enter

After a minute or so you should see the Visual Studio Code shortcut in the Start Menu, Installation Directory, and Programs and Features in the Control Panel.

Software Title:Microsoft Visual Studio Code (32-bit)
Vendor:Microsoft Corporation
Architecture:x86
Installer Type:EXE
Silent Install Switch:VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode
Silent Uninstall Switch (32-bit System)"%ProgramFiles%\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART
Silent Uninstall Switch (64-bit System)"%ProgramFiles(x86)%\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART
Download Link:https://code.visualstudio.com/download
Video Tutorial:Visual Studio Code Silent Install (How-To Guide) Video
PowerShell Script:https://silentinstallhq.com/visual-studio-code-install-and-uninstall-powershell/
Detection Script:https://silentinstallhq.com/create-a-custom-detection-script-for-visual-studio-code-powershell/

Microsoft Visual Studio Code 64-bit Silent Install (EXE)

  1. Navigate to: https://code.visualstudio.com/download
  2. Select the 64-bit System Installer
  3. Download the VSCodeSetup-x64-x.y.z.exe to a folder created at (C:\Downloads)
  4. Open an Elevated Command Prompt by Right-Clicking on Command Prompt and select Run as Administrator
  5. Navigate to the C:\Downloads folder
  6. Enter the following command:
    • VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode
  7. Press Enter

After a minute or so you should see the Visual Studio Code shortcut in the Start Menu, Installation Directory, and Programs and Features in the Control Panel.

Software Title:Microsoft Visual Studio Code (64-bit)
Vendor:Microsoft Corporation
Architecture:x64
Installer Type:EXE
Silent Install Switch:VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode
Silent Uninstall Switch:"%ProgramFiles%\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART
Download Link:https://code.visualstudio.com/docs/?dv=win64
Video Tutorial:Visual Studio Code Silent Install (How-To Guide) Video
PowerShell Script:https://silentinstallhq.com/visual-studio-code-install-and-uninstall-powershell/
Detection Script:https://silentinstallhq.com/create-a-custom-detection-script-for-visual-studio-code-powershell/

The information above provides a quick overview of the software title, vendor, silent install, and silent uninstall switches. The download links provided take you directly to the vendors website. Continue reading if you are interested in additional details and configurations.


Additional Configurations

Create a Visual Studio Installation Log File

The Visual Studio Code installer offers the option to generate a log file during installation to assist with troubleshooting should any problems arise. You can use the following commands to create a verbose log file with details about the installation.

Visual Studio Code Silent Install (32-bit) with Logging

VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode /LOG="%WINDIR%\Temp\VSCode32-Install.log"

Visual Studio Code Silent Install (64-bit) with Logging

VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode /LOG="%WINDIR%\Temp\VSCode64-Install.log"

Change Visual Studio Code Default Installation Directory

You can also change the default installation directory by using the following command line parameters. In this example, I’m installing Visual Studio Code to “C:\VS_Code”

Visual Studio Code (32-bit)

VSCodeSetup-ia32-x.y.z.exe /DIR="C:\VS_Code" /VERYSILENT /NORESTART /MERGETASKS=!runcode

Visual Studio Code (64-bit)

VSCodeSetup-x64-x.y.z.exe /DIR="C:\VS_Code" /VERYSILENT /NORESTART /MERGETASKS=!runcode

Exclude Visual Studio Code PATH Environment Variable

Visual Studio Code Silent Install (32-bit) with No PATH Environment Variable

VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,!addtopath

Visual Studio Code Silent Install (64-bit) with No PATH Environment Variable

VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,!addtopath

Include Visual Studio Code Desktop Shortcut

Visual Studio Code Silent Install (32-bit) with Desktop Shortcut

VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,desktopicon

Visual Studio Code Silent Install (64-bit) with Desktop Shortcut

VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,desktopicon

Add Visual Studio Code Windows Explorer File Context Menu

Visual Studio Code Silent Install (32-bit) with File Context Menu

VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,addcontextmenufiles

Visual Studio Code Silent Install (64-bit) with File Context Menu

VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,addcontextmenufiles

Add Visual Studio Code Windows Explorer Folder Context Menu

Visual Studio Code Silent Install (32-bit) with Folder Context Menu

VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,addcontextmenufolders

Visual Studio Code Silent Install (64-bit) with Folder Context Menu

VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,addcontextmenufolders

Register Visual Studio Code for Supported File Types

Visual Studio Code Silent Install (32-bit) with Associated File Types

VSCodeSetup-ia32-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,associatewithfiles

Visual Studio Code Silent Install (64-bit) with Associated File Types

VSCodeSetup-x64-x.y.z.exe /VERYSILENT /NORESTART /MERGETASKS=!runcode,associatewithfiles

Disable Visual Studio Code Auto Updates

  • Open Notepad or your favorite text editor
  • Add the following lines:
{
    "update.mode": "none",
    "update.enableWindowsBackgroundUpdates": false,
    "extensions.autoUpdate": false,
    "extensions.autoCheckUpdates": false
}
  • Save the file to C:\Downloads\ and name it: settings.json
  • Open an Elevated Command Prompt by Right-Clicking on Command Prompt and select Run as Administrator
  • Navigate to the C:\Downloads\ folder
  • Enter the following command to copy the settings.json to “C:\Users\%Username%\AppData\Roaming\Code\User\”:
xcopy /y ".\settings.json" "%AppData%\Code\User\"

How to Uninstall Visual Studio Code Silently

Check out the following posts for a scripted solution:

Visual Studio Code Install and Uninstall (PowerShell)
Visual Studio Code Silent Uninstall (PowerShell)
  1. Open an Elevated Command Prompt by Right-Clicking on Command Prompt and select Run as Administrator
  2. Enter one of the following commands:

Visual Studio Code 32-bit Silent Uninstall on 32-bit System

"%ProgramFiles%\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART

Visual Studio Code 32-bit Silent Uninstall on 64-bit System

"%ProgramFiles(x86)%\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART

Visual Studio Code 64-bit Silent Uninstall on 64-bit System

"%ProgramFiles%\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART

Visual Studio Code (User) Silent Uninstall

"%LocalAppData%\Programs\Microsoft VS Code\unins000.exe" /VERYSILENT /NORESTART

Always make sure to test everything in a development environment prior to implementing anything into production. The information in this article is provided “As Is” without warranty of any kind.

Jason Bergner

I am an accomplished Software Engineer at Patch My PC, leveraging more than 18 years of hands-on experience in Configuration Manager administration and application packaging. I am driven by a genuine passion for solving complex problems and consistently strive to discover innovative and effective solutions. Sharing my extensive knowledge of application deployments is a true joy for me, and I am honored to contribute to the community here at Silent Install HQ.

Recent Posts