共用方式為


Find, install, and manage extensions for Visual Studio

Use Extension Manager

In the Visual Studio IDE, Extension Manager is the tool that you use to find, install, and manage Visual Studio extensions. To open Extension Manager, select Extensions > Manage Extensions. Or enter extensions in the search box and select Manage Extensions.

The left pane categorizes extensions by those that are available on Visual Studio Marketplace (Browse), those that are installed, and those that have updates available. The Roaming tab lists all the Visual Studio extensions that you have installed on any machine or instance of Visual Studio. It's designed to let you find your favorite extensions more easily.

Find and install extensions

You can install extensions from Visual Studio Marketplace or from Extension Manager in Visual Studio.

To install extensions from Visual Studio:

  1. Select Extensions > Manage Extensions. Find the extension you want to install. (If you know the name or part of the name of the extension, you can search in the search box.)

  2. Select Install.

If you try to install an extension that has dependencies, the installer determines whether they're already installed. If they aren't installed, Extension Manager lists the dependencies that must be installed before you can install the extension.

Install extensions without using Extension Manager

Extensions that are packaged in .vsix files might be available in locations other than Visual Studio Marketplace. The Extensions > Extension Manager dialog can't detect these files, but you can install a .vsix file by double-clicking the file or selecting the file and then selecting Enter. If you encounter permission issues, ensure that you're running Visual Studio as an administrator. After that, just follow the instructions. When the extension is installed, you can use Extension Manager to enable it, disable it, or uninstall it.

Note

  • Visual Studio Marketplace contains both VSIX-based and MSI-based extensions. Extension Manager can't enable or disable MSI-based extensions.
  • If an MSI-based extension includes an extension.vsixmanifest file, the extension appears in Extension Manager.

Uninstall or disable an extension

If you want to stop using an extension, you can either disable it or uninstall it. Disabling an extension keeps it installed but unloaded. Find the extension and select Uninstall or Disable. Restart Visual Studio to unload a disabled extension.

Note

You can disable VSIX-based extensions but not extensions that are installed via MSI. MSI-installed extensions can only be uninstalled.

Manage extensions

This section provides information about managing extensions for an organization, automatic extension updates, and unresponsiveness notifications.

Per-user and administrative extensions

Most extensions are per-user extensions and are installed in the %LocalAppData%\Microsoft\VisualStudio\<Visual Studio version>\Extensions\ folder. A few extensions are administrative extensions and are installed in the <Visual Studio installation folder>\Common7\IDE\Extensions\ folder.

To protect your system against extensions that might contain errors or malicious code, you can restrict per-user extensions to load only when Visual Studio is run with normal user permissions. This causes per-user extensions to be disabled when Visual Studio is run with elevated permissions.

To restrict when per-user extensions load:

  1. Open the extensions options page (Tools > Options > Environment > Extensions).

  2. Clear the Load per user extensions when running as administrator checkbox.

  3. Restart Visual Studio.

Automatic extension updates

Crash and unresponsiveness notifications

Visual Studio notifies you if it suspects that an extension was involved in a crash during a previous session. When Visual Studio crashes, it stores the exception stack. The next time Visual Studio starts, it examines the stack, starting with the leaf and working towards the base. If Visual Studio determines that a frame belongs to a module that's part of an installed and enabled extension, it shows a notification.

Visual Studio also notifies you if it suspects that an extension is causing the UI to be unresponsive.

When you see one of these notifications, you can ignore it or take one of the following actions:

  • Select Disable this extension. Visual Studio disables the extension and lets you know whether you need to restart your system for the disable operation to take effect. You can re-enable the extension in the Extensions > Manage Extensions dialog.

  • Select Never show this message again.

    • If the notification concerns a crash in a previous session, Visual Studio no longer shows a notification when a crash associated with the extension occurs. Visual Studio still shows notifications when unresponsiveness can be associated with the extension or for crashes or unresponsiveness that can be associated with other extensions.
    • If the notification concerns unresponsiveness, the IDE no longer shows a notification when the extension is associated with unresponsiveness. Visual Studio still shows crash-related notifications for the extension and crash-related and unresponsiveness-related notifications for other extensions.
  • Select Learn more.

  • Select the X at the end of the notification to dismiss the notification. A new notification appears if the extension is associated with a crash or with UI unresponsiveness in the future.

Note

A UI unresponsiveness notification or crash notification means that one of the extension's modules was on the stack when the UI was unresponsive or when the crash occurred. It doesn't necessarily mean that the extension caused the problem. It's possible that the extension called code that's part of Visual Studio, which in turn resulted in unresponsive UI or a crash. However, the notification might still be useful if the extension that led to the UI unresponsiveness or crash isn't important to you. In this case, disabling the extension avoids the UI unresponsiveness or crash in the future.

Marketplace protections

The Visual Studio Marketplace for extensions employs several mechanisms to protect you from malicious extensions:

  • Malware scanning: The Marketplace runs a malware scan on each extension package that's published to ensure its safety. The scan, which uses several antivirus engines, is run for each new extension and for each extension update. Until the scan is all clear, the extension won't be published in the Marketplace for public usage.

  • Verified publishers: Publishers can verify (blue check mark) their identity by proving domain ownership. It shows that the publisher has proven domain-name ownership to the Marketplace. It also shows that the Marketplace has verified both the existence of the domain and the good standing of the publisher on the Marketplace for at least six months.

  • Unusual usage monitoring: The Marketplace monitors the downloads and usage patterns of extensions to detect unusual behavior.

  • Name squatting: The Marketplace stops extension authors from stealing the names of official publishers, such as Microsoft or RedHat, and popular extensions, like GitHub Copilot.

  • Block List: If a malicious extension is reported and verified, or a vulnerability is found in an extension dependency, the extension is removed from the Marketplace.

  • Extension Signature Verification: The Visual Studio Marketplace signs all extensions when they're published. Visual Studio checks this signature when you install an extension to verify the integrity and the source of the extension package.

  • Secret Scanning: The Marketplace automatically scans every newly published extension for secrets such as API keys or credentials (e.g., Azure DevOps PAT tokens). If any secrets are detected, publishing is blocked to prevent potential security risks.

Learn about these measures in the Security and Trust in Visual Studio Marketplace blog post.

Samples

When you install an online sample, the solution is stored in two locations:

  • A working copy is stored in the location that you specified when you created the project.

  • A separate master copy is stored on your computer.

You can use the Extensions > Manage Extensions dialog to perform these samples-related tasks:

  • List the master copies of samples that you have installed.

  • Disable or uninstall the master copy of a sample.

  • Install Sample Packs, which are collections of samples that relate to a technology or feature.

  • Install individual online samples.

  • View update notifications when source code changes are published for installed samples.

  • Update the master copy of an installed sample when there's an update notification.