How to Pin and Exclude Packages from Updates in Windows 11 Using Winget

The Windows Package Manager (winget) provides a unified command-line interface for discovering, installing, and upgrading software on Windows 11. Running winget upgrade --all allows power users and system administrators to update every installed application in a single automated step.

However, running unconditional mass upgrades often causes software regressions. Enterprise productivity suites may require a specific legacy build, developer SDKs may depend on fixed compiler versions, or newly published vendor releases might introduce breaking user interface changes. Windows Package Manager includes a native pinning subsystem via the winget pin command, allowing users to prevent specific applications from upgrading automatically.

Understanding Winget Pin Types

Windows Package Manager supports three distinct pinning behaviours:

  • Pinning: Restricts upgrades to a specified version pattern or prevents upgrades entirely while continuing to display available update notices in winget upgrade tables.
  • Blocking: Completely suppresses the package from the upgrade candidates list and strictly prevents the package from being upgraded, even if explicitly invoked.
  • Gating: Restricts updates to specific version increments (for example, pinning a package to prevent major version bumps while permitting minor security patches).

Listing Active Package Pins

To inspect which applications are currently subject to pinning restrictions on your system:

  1. Right-click the Start button on Windows 11 and select Terminal (or PowerShell).
  2. Run the following command:
winget pin list

If no pins have been established yet, the command returns an empty summary table.

Pinning an Application to Block Upgrades

To completely block an application from upgrading during global or targeted update sweeps, use the --blocking flag:

# Block updates for a specific package ID
winget pin add --id VideoLAN.VLC --blocking

When an application is blocked, running winget upgrade --all automatically skips the software, safeguarding your existing installation.

Pinning to a Specific Version Range

If you want to receive minor bug fixes and security revisions within a major release branch while blocking disruptive version updates, specify a target version wildcard:

# Pin Python to version branch 3.11.*
winget pin add --id Python.Python.3.11 --version "3.11.*"

In this configuration, winget will permit updates within the 3.11 release cycle (such as 3.11.8 to 3.11.9) but will block upgrades to Python 3.12.

Removing Application Pins

When you are ready to upgrade a pinned application after confirming compatibility:

# Remove the pin using the package ID
winget pin remove --id VideoLAN.VLC

Once removed, the application will appear in standard upgrade queries and can be updated normally.

Essential Winget Pin Commands Summary

Action PowerShell / Command Prompt Syntax Description
View Active Pins winget pin list Displays all currently pinned or blocked packages.
Block Package winget pin add --id <PackageID> --blocking Completely suppresses upgrades for the specified application.
Pin Version winget pin add --id <PackageID> --version "<Version>" Restricts upgrades to a specified version or release pattern.
Remove Pin winget pin remove --id <PackageID> Unpins the package, restoring standard upgrade capability.
Reset All Pins winget pin reset --force Removes all established package pins across the entire system.

Leveraging the winget pin command ensures you maintain granular control over your Windows 11 software environment without sacrificing the convenience of automated package updates.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.