Are you tired of manually searching for and downloading software on your Windows machine? Look no further than Winget, the package manager for Windows. With Winget, you can easily install, update, and manage your software from the command line. In this article, we'll show you how to install Winget using PowerShell, so you can start streamlining your software management process.
If you see a version number (e.g., v1.7.xxx ), you are done. If you get an error, proceed below.
If your Windows installation is recent, the WinGet client might already be present but malfunctioning, or the module is ready to be installed from the PowerShell Gallery. This method is the recommended approach for modern systems. Run the following script in an window: powershell
winget install --id Google.Chrome --silent --accept-source-agreements --accept-package-agreements Use code with caution. install winget using powershell hot
If you are looking for the fastest ("hot") way to get WinGet running on your machine, using PowerShell is the top choice. This article will guide you through the process, covering multiple methods for both Windows 10 and Windows 11. What is WinGet?
If the installation was successful, PowerShell will output the current version string (e.g., v1.9.2521 ). Initializing the Sources
: The script fails during installation, often with dependency or permission-related errors. Are you tired of manually searching for and
This command allows the script to run in the current PowerShell window only, preserving the system's default security policy for all other operations. After setting this, run the installation script normally.
# Define download paths $downloadsFolder = "$env:USERPROFILE\Downloads" if (-not (Test-Path $downloadsFolder)) New-Item -ItemType Directory -Path $downloadsFolder # 1. Download and Install VCLibs Dependency $vclibsUrl = "https://aka.ms" Invoke-WebRequest -Uri $vclibsUrl -OutFile "$downloadsFolder\VCLibs.appx" Add-AppxPackage -Path "$downloadsFolder\VCLibs.appx" # 2. Download and Install UI Xaml Dependency $uiXamlUrl = "https://github.com" Invoke-WebRequest -Uri $uiXamlUrl -OutFile "$downloadsFolder\UiXaml.appx" Add-AppxPackage -Path "$downloadsFolder\UiXaml.appx" # 3. Fetch Latest Winget Release from GitHub API $repo = "microsoft/winget-cli" $releases = "https://github.com" $latestRelease = Invoke-RestMethod -Uri $releases $asset = $latestRelease.assets | Where-Object $_.name -like "*.msixbundle" | Select-Object -First 1 # 4. Download and Install Winget if ($asset) $wingetPath = "$downloadsFolder\$($asset.name)" Invoke-WebRequest -Uri $asset.browser_download_url -OutFile $wingetPath Add-AppxPackage -Path $wingetPath Write-Host "Winget installed successfully!" -ForegroundColor Green else Write-Error "Failed to find the latest Winget bundle." Use code with caution. How this script works:
You should see a list of commands. This means your installation worked. Why This Method is Hot No web browsers needed. No store account required. Fully automatic process. Takes under one minute. In this article, we'll show you how to
If you think winget is installed but "hot" or broken, use the built-in repair functionality: powershell # Re-registers the app installer for the current user Get-AppxPackage Microsoft.DesktopAppInstaller | {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml" Use code with caution. Copied to clipboard Verification
How to Install Winget Using PowerShell Fast The Windows Package Manager (Winget) is a built-in command-line tool that automates software installation. Sometimes Winget is missing, corrupted, or broken on fresh Windows installations. You can force-install or repair Winget instantly using PowerShell.