How to fix VS Code extension installation errors ?

👤 Diwas Poudel    🕒 19 Aug 2023    📁 TECH

There could be various reasons you are getting errors while installing the vs code extension let's look at them one by one and try to get fix them.

Reason for getting those errors:

  1. Weak or no internet connection
  2. Corrupted Extension
  3. Version incompatibility issue
  4. Extension Dependency Issues 
Video content related to this article :

Fix Visual Studio Code extension installation Error

Let's look at how to fix this issue.

1. Check your internet connection

Check the internet connection and ensure that the internet connection is ok. If the connection is ok then close the visual studio again and try to install the extension again.

2. Clear Visual Studio Cache 

The cache contains frequently accessed data such as extension metadata, file previews, and search results. The location of Visual Studio Cache based on OS is as follows:

For Windows 


For macOS

~/Library/Application Support/Code/Cache

For Linux


Goto this path and delete the content of the Cache folder. Then again try installing the extension.

Note that deleting the cache will not delete your installed extension and settings.

3. Check if there are any dependencies on other package and extension

Just check the extensions documentation to see whether there are any known dependency issues and required it to install before installing the current extension.

4. Update Visual Studio Code

Ensure that you are using the latest version of VS Code.  Updates often include bug fixes and improvements that can address installation issues.

Visual Studio Code automatically updates to the latest version. If you are not getting the latest update then follow the below steps.

Steps to update Visual Studio Code.

  1. Open Visual Studio Code
  2. Click on Help 
  3. Click on Check for updates
    Check for updates
    fig. Click on Check for updates 
  4. Then try installing the extension again.

5. Download Visual Studio Extension Locally 

If nothing works for you then you can download the visual studio extension locally. Here are the steps for downloading the visual studio extension locally.

  1. Goto Visual Studio Code Market Place by clicking on this link:
    Visual Studio Code Market Place
    fig. Visual Studio Code Market Place
  2. Search for the extension you want to download.
    Here, I am searching Live Server. Click on it.
    Search for extension
    fig. Search for extension you like to install locally
  3. Click on "Download extension". Downloading might take some time. Wait for it.
    Click on Download extension link
     Fig. Click on the Download extension link
  4. Goto Visual Studio Code again and then click on Extension.
  5. Click on 3 horizontal dots at the top. Next, click on Install from VSIX
    Click on Install from VSIX
    fig. Click on Install from VSIX 
  6. Search for an extension and select it.
  7. Click on Trust Workspace & Install as enabling this extension requires a trusted workspace.
Click on Trust Workspace & Install button
fig. Click on Trust Workspace & Install button



These 5 ways may help you to fix vs code extension installation issue.