cheat sheet

winget Package Manager

Installing, upgrading, and managing packages with Windows Package Manager.

winget Package Manager

What it is

winget is Microsoft's official command-line package manager for Windows, maintained by Microsoft and backed by the Windows Package Manager Community Repository on GitHub. It can install, upgrade, and remove applications by ID, search the repository, and export/import a full list of installed packages for reproducible machine setup. Reach for winget when you want to automate Windows software installation in scripts or set up a new machine consistently — the Windows equivalent of apt-get or brew.

What's new in 2026

ChannelLatestReleasedHighlights
Stablev1.28.2402026-04-17Font install/uninstall, MCP server for agent-driven installs, enhanced logging controls
Previewv1.29.170-preview2026-05-07Source priority (experimental), export of --override / --custom args, universal --no-progress, MCP upgrade support

Notable additions across the v1.28 / v1.29 series:

  • --no-progress is now valid on every command — set it in CI to keep logs clean without grepping out spinner glyphs.
  • winget export captures the --override and --custom arguments used at install time and re-applies them on winget import, so silent-MSI installs survive a round-trip.
  • Source priority (sourcePriority setting, experimental) lets you bias search results when a package is published in multiple sources (e.g., winget plus msstore).
  • Built-in MCP serverwinget exposes itself as a Model Context Protocol server, so Claude Code, Copilot, and other MCP clients can call winget install directly with managed prompts.
  • Font installwinget install accepts font packages (.ttf / .otf published as MSIX font packages) and installs them per-user or system-wide.
  • RFC 3161 timestamp server support in the source signing pipeline (relevant only if you self-host a private source).

Upgrade:

powershell
winget upgrade Microsoft.AppInstaller
# or, if you want the preview ring
winget install --id Microsoft.WindowsPackageManagerClient -s msstore

Install packages

Install by package ID (most reliable):

powershell
winget install --id Git.Git

Output:

text
Found Git [Git.Git] Version 2.44.0
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Downloading https://github.com/git-for-windows/git/releases/download/v2.44.0.windows.1/Git-2.44.0-64-bit.exe
  ██████████████████████████████  58.2 MB / 58.2 MB
Successfully verified installer hash
Starting package install...
Successfully installed

Install silently (no UI prompts):

powershell
winget install --id Git.Git --silent

Install a specific version:

powershell
winget install --id Git.Git --version 2.44.0

Install multiple packages at once:

powershell
winget install --id Microsoft.VisualStudioCode
winget install --id Volta.Volta
winget install --id Python.Python.3.12
winget install --id Docker.DockerDesktop

Search by keyword:

powershell
winget search "node"

Output:

text
Name                          Id                            Version   Match          Source
----------------------------------------------------------------------------------------------
Node.js                       OpenJS.NodeJS                 22.1.0    Moniker: node  winget
Node.js (LTS)                 OpenJS.NodeJS.LTS             20.12.2   Moniker: node  winget
Nodemon                       Nodemon.Nodemon               3.1.0                    winget
Node Version Switcher         jasongin.nvs                  1.7.1                    winget
Volta                         Volta.Volta                   1.1.1                    winget
...

Search by name prefix:

powershell
winget search --name "JetBrains"

Show full package info:

powershell
winget show --id Microsoft.VisualStudioCode

Output:

text
Found Visual Studio Code [Microsoft.VisualStudioCode] Version 1.88.1
Publisher: Microsoft Corporation
Publisher Url: https://code.visualstudio.com
Publisher Support Url: https://github.com/microsoft/vscode/issues
Author: Microsoft Corporation
Moniker: vscode
Description:
  Visual Studio Code is a lightweight but powerful source code editor which runs on your desktop and is
  available for Windows, macOS and Linux. It comes with built-in support for JavaScript, TypeScript and
  Node.js and has a rich ecosystem of extensions for other languages and runtimes.
Homepage: https://code.visualstudio.com/
License: Microsoft Software License Terms
License Url: https://code.visualstudio.com/license
Copyright: Copyright (C) Microsoft Corporation. All rights reserved.
Tags:
  code-editor
  editor
  ide
  vscode
Installer:
  Installer Type: exe
  Install Modes: interactive, silent
  Installer Url: https://update.code.visualstudio.com/1.88.1/win32-x64/stable
  Installer Sha256: a3f5...c7d9

Upgrade

Upgrade a specific package:

powershell
winget upgrade --id Git.Git

Output:

text
Found Git [Git.Git] Version 2.44.0
Downloading https://github.com/git-for-windows/git/releases/download/v2.44.0.windows.1/Git-2.44.0-64-bit.exe
  ██████████████████████████████  58.2 MB / 58.2 MB
Successfully verified installer hash
Starting package install...
Successfully installed

Upgrade all installed packages:

powershell
winget upgrade --all

Output:

text
Name                   Id                            Version    Available  Source
-----------------------------------------------------------------------------------
Git                    Git.Git                       2.43.0     2.44.0     winget
PowerShell             Microsoft.PowerShell          7.4.1      7.4.2      winget
Windows Terminal       Microsoft.WindowsTerminal     1.19.10573 1.19.11213 winget
3 upgrades available.
Starting upgrades...
Successfully installed Git [Git.Git] 2.44.0
Successfully installed PowerShell [Microsoft.PowerShell] 7.4.2
Successfully installed Windows Terminal [Microsoft.WindowsTerminal] 1.19.11213

List packages with available upgrades:

powershell
winget upgrade

Output:

text
Name                   Id                            Version    Available  Source
-----------------------------------------------------------------------------------
Git                    Git.Git                       2.43.0     2.44.0     winget
PowerShell             Microsoft.PowerShell          7.4.1      7.4.2      winget
Windows Terminal       Microsoft.WindowsTerminal     1.19.10573 1.19.11213 winget
3 upgrades available.

Export & import (reproducible setup)

Export all installed packages to JSON:

powershell
winget export --output packages.json

Import and install from JSON:

powershell
winget import --import-file packages.json --ignore-unavailable

Useful packages.json snippet

json
{
  "$schema": "https://aka.ms/winget-packages.schema.2.0.json",
  "WinGetVersion": "1.8.0",
  "CreationDate": "2026-04-23",
  "Sources": [
    {
      "Packages": [
        { "PackageIdentifier": "Git.Git" },
        { "PackageIdentifier": "Microsoft.VisualStudioCode" },
        { "PackageIdentifier": "Volta.Volta" },
        { "PackageIdentifier": "Python.Python.3.12" },
        { "PackageIdentifier": "Notepad++.Notepad++" }
      ],
      "SourceDetails": {
        "Argument": "https://cdn.winget.microsoft.com/cache",
        "Identifier": "Microsoft.Winget.Source_8wekyb3d8bbwe",
        "Name": "winget",
        "Type": "Microsoft.PreIndexed.Package"
      }
    }
  ]
}

List installed packages

Shows every package winget knows about on the machine, including apps installed outside of winget (detected via the Windows Add/Remove Programs registry). Use this to audit what is installed or to look up an exact package ID before upgrading or uninstalling.

powershell
winget list

Output:

text
Name                          Id                              Version        Source
---------------------------------------------------------------------------------------
Git                           Git.Git                         2.44.0         winget
Visual Studio Code            Microsoft.VisualStudioCode      1.88.1         winget
Python 3.12                   Python.Python.3.12              3.12.3         winget
Windows Terminal              Microsoft.WindowsTerminal       1.19.11213     winget
PowerShell 7-x64              Microsoft.PowerShell            7.4.2          winget
Notepad++                     Notepad++.Notepad++             8.6.4          winget
7-Zip 23.01 (x64)             7zip.7zip                       23.01.00.0     winget
...

Uninstall

Removes the package by invoking its own uninstaller silently. Always prefer --id over a name match to avoid accidentally uninstalling the wrong package.

powershell
winget uninstall --id Git.Git

Output:

text
Found Git [Git.Git]
Starting package uninstall...
Successfully uninstalled

Configured sources

winget can pull packages from multiple repositories; by default it ships with the winget community repo and the Microsoft Store. Check this if winget search returns unexpected results or if a corporate environment has added a private feed.

powershell
winget source list

Output:

text
Name    Argument                                                         Explicit
----------------------------------------------------------------------------------
winget  https://cdn.winget.microsoft.com/cache                          false
msstore https://storeedgefd.dsx.mp.microsoft.com/v9.0/manifestSearch    false

Common IDs reference

AppID
GitGit.Git
VS CodeMicrosoft.VisualStudioCode
Node (Volta)Volta.Volta
Python 3.12Python.Python.3.12
7-Zip7zip.7zip
Windows TerminalMicrosoft.WindowsTerminal
PowerShell 7Microsoft.PowerShell
Notepad++Notepad++.Notepad++
GitHub CLIGitHub.cli
Cloudflare WranglerCloudflare.wrangler

Syntax and global flags

winget follows a verb noun args shape that mirrors git and apt. Across every command, a small set of global flags adjusts behaviour — disabling interactivity (--disable-interactivity), accepting EULAs ahead of time (--accept-source-agreements, --accept-package-agreements), and forcing exact ID matches (--exact). Master these once and every subcommand inherits them.

powershell
winget <command> [<subcommand>] [<id-or-query>] [options]

The flags that apply to almost every subcommand:

FlagMeaning
--id <PackageIdentifier>Match by exact package ID (preferred over name)
--name <DisplayName>Match by display name (less reliable; can be ambiguous)
--moniker <moniker>Match by friendly alias (e.g. vscode for VS Code)
--source <source>Constrain to one source (winget, msstore, custom)
--exact, -eDisable substring matching
--version <ver>Pin a specific version
--silent, -hNo UI — required for unattended scripts
--interactive, -iForce the installer GUI to appear
--accept-source-agreementsPre-accept new source EULAs
--accept-package-agreementsPre-accept package licence prompts
--disable-interactivityFail rather than prompt
`--scope usermachine`
`--architecture x86x64
`--installer-type exemsi
--location <path>Override install directory (manifest-dependent)
--log <path>Write a detailed log file
--no-upgradeSkip upgrade if already installed
--header "X: Y"Add an HTTP header to REST source requests

The single most useful pattern for CI/CD scripts:

powershell
winget install --id Git.Git --exact --silent `
    --accept-source-agreements --accept-package-agreements `
    --disable-interactivity

Source management

A source is a catalogue of available packages — by default winget ships with two: the community winget repo (the microsoft/winget-pkgs GitHub manifests) and msstore (the Microsoft Store search API). Corporate environments and air-gapped networks add private REST sources or self-hosted index packages. Add, remove, refresh, reset, and export sources with the winget source subcommand.

List the configured sources:

powershell
winget source list

Output:

text
Name    Argument                                                         Explicit
----------------------------------------------------------------------------------
winget  https://cdn.winget.microsoft.com/cache                          false
msstore https://storeedgefd.dsx.mp.microsoft.com/v9.0/manifestSearch    false

Add a private source backed by a REST endpoint:

powershell
winget source add --name corp --arg https://winget.corp.example.com/v1/ --type "Microsoft.Rest"

Output:

text
Adding source: corp -> https://winget.corp.example.com/v1/
Verifying source...
Done

Update one or all sources (refresh the local index):

powershell
winget source update
winget source update --name winget

Reset all sources to defaults (clears local cache and re-adds the built-ins):

powershell
winget source reset --force

Remove a source:

powershell
winget source remove --name msstore

Export a source definition to JSON so other machines can re-add it:

powershell
winget source export > sources.json

Source types

TypeHostingUse when
Microsoft.PreIndexed.PackageMSIX package containing a pre-indexed SQLite DBPublic community repo and air-gapped mirrors
Microsoft.RestHTTPS REST API following the winget REST source specPrivate corporate catalogues with frequent updates

For a self-hosted REST source, Microsoft publishes a reference implementation on Azure Functions. Stand it up with winget-cli-restsource, point a Microsoft.Rest source at it, and your fleet can be patched from packages your security team has vetted.

Manifests — the YAML behind every package

Every package in the community repo is described by a YAML manifest checked into microsoft/winget-pkgs at manifests/<l>/<Publisher>/<Package>/<version>/. Manifests are split into four YAML files: a version file, a defaultLocale file, optional locale files, and an installer file. Each is validated against a JSON Schema; the winget validate subcommand checks a manifest folder for compliance before submission.

The four manifest files for a given version:

text
manifests/g/Git/Git/2.44.0/
├── Git.Git.yaml                  # version metadata
├── Git.Git.installer.yaml        # installer URL, hash, args, switches
├── Git.Git.locale.en-US.yaml     # default locale strings
└── Git.Git.locale.fr-FR.yaml     # optional additional locales

A minimal version manifest (Git.Git.yaml):

yaml
PackageIdentifier: Git.Git
PackageVersion: 2.44.0
DefaultLocale: en-US
ManifestType: version
ManifestVersion: 1.6.0

A minimal installer manifest (Git.Git.installer.yaml):

yaml
PackageIdentifier: Git.Git
PackageVersion: 2.44.0
InstallerType: inno
Scope: machine
InstallModes:
  - interactive
  - silent
  - silentWithProgress
UpgradeBehavior: install
ReleaseDate: 2026-03-15
Installers:
  - Architecture: x64
    InstallerUrl: https://github.com/git-for-windows/git/releases/download/v2.44.0.windows.1/Git-2.44.0-64-bit.exe
    InstallerSha256: A1B2C3D4E5F6...DEADBEEF
    InstallerSwitches:
      Silent: /VERYSILENT /NORESTART
      Custom: /COMPONENTS="ext,gitlfs,assoc"
ManifestType: installer
ManifestVersion: 1.6.0

A minimal defaultLocale manifest (Git.Git.locale.en-US.yaml):

yaml
PackageIdentifier: Git.Git
PackageVersion: 2.44.0
PackageLocale: en-US
Publisher: The Git Development Community
PackageName: Git
PackageUrl: https://git-scm.com/
License: GPL-2.0
ShortDescription: Distributed SCM that handles small to large projects with speed.
Description: |-
  Git is a free and open source distributed version control system designed
  to handle everything from small to very large projects with speed and efficiency.
Tags:
  - scm
  - version-control
  - cli
ManifestType: defaultLocale
ManifestVersion: 1.6.0

Validate a manifest folder locally before submitting a PR:

powershell
winget validate --manifest .\manifests\g\Git\Git\2.44.0

Output:

text
Manifest validation succeeded.

Submit by opening a PR to microsoft/winget-pkgs; the CI runs wingetcreate checks and a signed-installer scan before a maintainer merges.

Authoring with wingetcreate

wingetcreate is the official manifest-generation tool. Install it from winget itself and use the new subcommand for greenfield manifests or update to bump an existing one to a new version.

powershell
winget install --id Microsoft.WingetCreate

# Create a new manifest from an installer URL
wingetcreate new https://example.com/downloads/myapp-1.0.0.exe

# Bump an existing package to a new version
wingetcreate update Git.Git --version 2.45.0 `
    --urls https://github.com/git-for-windows/git/releases/download/v2.45.0.windows.1/Git-2.45.0-64-bit.exe `
    --submit --token ghp_*****

winget configure — Desired State Configuration

winget configure runs a YAML configuration file that declares a machine's desired state — installed packages, registry values, Windows features, modules, file content. It's the Windows analogue of Ansible playbooks or Chef recipes, built on the PowerShell DSC v3 resource model. The same YAML works for new-machine onboarding, CI runners, and dev-container parity, and it's idempotent: re-running it only changes drifted resources.

Run a configuration:

powershell
winget configure -f .\dev-machine.yaml --accept-configuration-agreements

Output:

text
Reading the configuration file...
Configuring the system...
Microsoft.Windows.Developer.DeveloperMode :: Set
   ✓ Already in desired state

WinGetPackage :: Git.Git
   ✓ Already installed (version 2.44.0)

WinGetPackage :: Microsoft.VisualStudioCode
   ✓ Installed version 1.88.1

WinGetPackage :: Microsoft.PowerShell
   ⚡ Installing version 7.4.2... Done

Configuration successfully applied.

A complete dev-machine.yaml covering the most common resources:

yaml
# yaml-language-server: $schema=https://aka.ms/configuration-dsc-schema/0.2
properties:
  configurationVersion: 0.2.0
  assertions:
    - resource: Microsoft.Windows.Developer/OsVersion
      directives:
        description: Require Windows 11 or later
        allowPrerelease: true
      settings:
        MinVersion: '10.0.22000'
  resources:
    - resource: Microsoft.Windows.Developer/DeveloperMode
      directives:
        description: Enable Developer Mode
        allowPrerelease: true
      settings:
        Ensure: Present

    - resource: Microsoft.WinGet.DSC/WinGetPackage
      id: git
      directives:
        description: Install Git
      settings:
        id: Git.Git
        source: winget

    - resource: Microsoft.WinGet.DSC/WinGetPackage
      id: vscode
      directives:
        description: Install VS Code
      settings:
        id: Microsoft.VisualStudioCode
        source: winget

    - resource: Microsoft.WinGet.DSC/WinGetPackage
      id: pwsh
      directives:
        description: Install PowerShell 7
      settings:
        id: Microsoft.PowerShell
        source: winget

    - resource: Microsoft.WinGet.DSC/WinGetPackage
      id: pyhton
      directives:
        description: Install Python 3.12
      settings:
        id: Python.Python.3.12
        source: winget

Validate the file without applying it (dry-run):

powershell
winget configure validate -f .\dev-machine.yaml

Show what would change:

powershell
winget configure show -f .\dev-machine.yaml

Common DSC resources you'll use in configurations:

ResourceSourceWhat it manages
Microsoft.WinGet.DSC/WinGetPackageMicrosoft.WinGet.DSC PowerShell moduleInstalls, upgrades, uninstalls packages
Microsoft.Windows.Developer/DeveloperModeMicrosoft.Windows.Developer moduleToggles Developer Mode
Microsoft.Windows.Developer/OsVersionsameAsserts OS version
PSDscResources/ScriptPSDscResourcesRuns arbitrary PowerShell as a resource
PSDscResources/RegistrysameRegistry keys and values
Microsoft.DSC.Transitional/RunCommandOnSetbuiltinImperative escape hatch

GitHub publishes a winget-dsc repository of community resources covering Visual Studio installations, Git config, WSL distros, fonts, and dev-tunnels.

Pinning — winget pin

winget pin locks a package at a specific version or range so subsequent winget upgrade runs ignore newer releases. It's the safety valve for "do not upgrade this one — production depends on its exact version" without blocking the rest of the fleet from getting routine patches.

powershell
# Pin a package at exactly its current version (gating mode)
winget pin add --id Python.Python.3.12

# Pin with a SemVer range
winget pin add --id OpenJS.NodeJS --version "20.*"

# Block the package from upgrade entirely
winget pin add --id Docker.DockerDesktop --blocking

# Pinning the *installed* version, not whatever's available now
winget pin add --id Python.Python.3.12 --installed

# List all pins
winget pin list

# Remove a pin
winget pin remove --id Python.Python.3.12

# Reset all pins
winget pin reset --force

Output (winget pin list):

text
Name                  Id                          Version    Source  Type
--------------------------------------------------------------------------------
Python 3.12           Python.Python.3.12          3.12.3     winget  Pinning
Node.js (LTS)         OpenJS.NodeJS               20.*       winget  Pinning
Docker Desktop        Docker.DockerDesktop                   winget  Blocking

The three pin modes:

ModeWhat it doesOverride
PinningExcludes from upgrade --all until version matches the pin specwinget upgrade --include-pinned
BlockingRefuses any upgrade or install attemptwinget pin remove first
GatingLocks the package to a version range; upgrades within the range proceedChange the range with --version

For an air-gapped fleet, ship winget pin export / winget pin import (Insiders builds only at time of writing) alongside winget export to reproduce the full state.

Settings — winget settings

winget settings opens the per-user configuration file in your default editor — a JSON document at %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\settings.json. It controls source autoupdate intervals, telemetry, experimental features, and per-source overrides.

powershell
# Open the settings JSON in the default editor
winget settings

# Export the active settings (Insiders 1.9+)
winget settings export

# Reset to defaults
winget settings --enable EnableSettingsExport

A typical settings.json covering the knobs people actually change:

json
{
  "$schema": "https://aka.ms/winget-settings.schema.json",
  "source": {
    "autoUpdateIntervalInMinutes": 5,
    "identifier": "winget"
  },
  "visual": {
    "progressBar": "rainbow",
    "anonymizeDisplayedPaths": true
  },
  "logging": {
    "level": "info",
    "channels": [ "core", "config", "cli" ]
  },
  "experimentalFeatures": {
    "configuration": true,
    "configureSelfElevate": true,
    "windowsFeature": true,
    "directMSI": true,
    "fonts": true
  },
  "installBehavior": {
    "preferences": {
      "scope": "user",
      "architectures": [ "x64", "x86" ],
      "installerTypes": [ "msix", "msi" ]
    },
    "requirements": {
      "scope": "machine"
    }
  },
  "telemetry": {
    "disable": true
  },
  "interactivity": {
    "disable": false
  },
  "uninstallBehavior": {
    "purgePortablePackage": true
  }
}

Notable settings:

SettingWhat it controls
source.autoUpdateIntervalInMinutesHow often winget source update runs implicitly
installBehavior.preferences.scopeDefault --scope for installs
installBehavior.preferences.architecturesPreferred order when multiple architectures available
installBehavior.requirements.installerTypesHard requirement vs preference
experimentalFeatures.configurationEnable winget configure (now stable on 1.7+)
telemetry.disableStop telemetry uploads
network.downloaderdefault or wininet (forces older HTTP client)

Comparison: winget vs choco vs scoop

Picking the right Windows package manager is a per-project decision. Each tool targets a different sweet spot.

Axiswingetchocoscoop
MaintainerMicrosoft (first-party)Chocolatey SoftwareCommunity (ScoopInstaller)
Default scopemachinemachineuser
Admin requiredusually yes (installer-dependent)yesno
Repo size (apps)~7000~9000+~2500 (focused on dev tools)
Package formatYAML manifest → original installerNuGet .nupkg + PowerShellJSON manifest
Reproducible setupwinget export + winget configure (DSC)choco export + packages.configscoop export + scoop import
Pin / holdwinget pinchoco pinscoop hold
Multiple versions side-by-sidelimitedlimited (one MSI per app)yes (scoop install nodejs@18 nodejs@20)
Telemetryoptionaloptionalnone
Self-updatewinget upgrade Microsoft.DesktopAppInstallerchoco upgrade chocolateyscoop update scoop
Air-gap / offlineREST + pre-indexed packageslocal source foldersGit-based buckets

For a one-paragraph rule of thumb: use winget first because it's pre-installed and supports DSC, fall back to choco for apps that haven't been ported to the community repo, and reach for scoop when you need user-scope CLI tools without UAC prompts or multiple side-by-side versions. See the choco cheat sheet and scoop cheat sheet for the matching deep dives.

Common pitfalls

  1. Installer hash does not match after an upstream re-upload — vendors sometimes overwrite a release file in place; the manifest's InstallerSha256 no longer matches. Bypass with --ignore-security-hash only as a temporary measure, then file an issue to update the manifest.
  2. No applicable installer found on ARM64 — many manifests only declare x64. Force x86 to run under emulation with --architecture x86, or wait for an ARM64-aware manifest.
  3. winget upgrade --all skips Microsoft Store apps — the Store source returns version Unknown, so winget can't tell whether an upgrade is needed. Run winget upgrade --all --include-unknown to force it.
  4. Multiple installed packages found matching input — your search term is ambiguous; add --exact and use --id. Pipe winget list through findstr first if unsure.
  5. winget configure errors with Resource not found — the DSC module backing the resource isn't installed; run Install-Module -Name Microsoft.WinGet.DSC -Force (PowerShell 7+).
  6. winget settings --enable flag has no --disable mirror — to undo, edit settings.json directly and remove the feature flag.
  7. Tabbed completion isn't on by default — run Register-ArgumentCompleter -Native -CommandName winget -ScriptBlock { ... } in $PROFILE; see the winget docs for the full block.

Real-world recipes

Fresh-machine bootstrap script

Run on a brand-new machine to install the standard developer toolchain.

powershell
winget configure --enable
winget configure -f .\dev-machine.yaml `
    --accept-configuration-agreements --accept-package-agreements

Patch one production app, hold everything else

powershell
# Block all upgrades except the critical app
foreach ($id in (winget list | Select-Object -Skip 2 | ForEach-Object {
    ($_ -split '\s{2,}')[1]
})) {
    if ($id -and $id -ne 'Git.Git') {
        winget pin add --id $id --blocking 2>$null
    }
}

winget upgrade --id Git.Git --silent

Reproducible CI runner provisioning

Drop these three files into a repo and any new GitHub Actions self-hosted runner can be set up from scratch:

powershell
# bootstrap.ps1
winget install --id Microsoft.PowerShell --silent
winget configure -f .\runner.yaml --accept-package-agreements
yaml
# runner.yaml
properties:
  configurationVersion: 0.2.0
  resources:
    - resource: Microsoft.WinGet.DSC/WinGetPackage
      settings: { id: GitHub.cli }
    - resource: Microsoft.WinGet.DSC/WinGetPackage
      settings: { id: Git.Git }
    - resource: Microsoft.WinGet.DSC/WinGetPackage
      settings: { id: OpenJS.NodeJS.LTS }

Local manifest install (no source needed)

When you need to test a manifest before submitting it upstream, winget can install from a local folder.

powershell
winget install --manifest .\manifests\m\MyCompany\InternalTool\1.0.0

Migrate from choco to winget

powershell
# Inventory existing choco packages
choco list --local-only --id-only > installed-choco.txt

# Look up the winget equivalent for each
Get-Content installed-choco.txt | ForEach-Object {
    winget search --query $_ --source winget | Select-Object -First 5
}

# Once mapped, uninstall via choco and install via winget

Sources