Windows command guide
How to Repair WinGet and Open Its Logs in Windows
WinGet problems are different from classic SFC or Windows Update corruption. Sometimes the package manager fails because its sources are stale, sometimes because the Desktop App Installer package is damaged, and sometimes because the real clue is only visible in the logs. This workflow combines the common repair sequence with faster log access.
This guide is written around the specific symptom-command match for repair winget and open its logs, not as a generic dump of terminal lines. That makes the page more useful for real troubleshooting and reduces the chance of running the wrong repair step.
winget --info
winget source reset --force
winget source update
Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe
winget --open-logs
Best place to run it
Command Prompt is the right execution context for this page. Even when elevation is not always required, using the right shell prevents syntax mistakes and makes the output easier to trust.
Fast repair workflow
- Start from the exact symptom on this page: winget cannot find packages it should normally find
- Run the service or app repair line exactly as shown: winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs.
- This workflow is tuned for this repair, so avoid mixing it with unrelated repair commands too early.
- Re-open the affected app, service, or feature and check whether the same component still fails.
- If the issue persists, check service state, dependencies, package integrity, or event logs before doing a broader repair.
Copyable wrapper script
Use this wrapper when you want the page command inside a clearer script block with start and finish prompts.
@echo off
echo Run this CMD sequence in the matching terminal window.
echo Starting targeted repair sequence...
winget --info
winget source reset --force
winget source update
Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe
winget --open-logs
echo.
echo Review the output before closing this window.
pause
Verification commands after the repair
These follow-up commands help you check whether the repair actually changed the Windows state that matters, instead of assuming success from a single line.
wsreset
Get-AppxPackage Microsoft.WindowsStore
What problem this command sequence is trying to solve
It targets a broken or unstable Windows Package Manager setup where winget commands fail, show source errors, or behave inconsistently.
- winget cannot find packages it should normally find.
- Source updates fail or return unexpected errors.
- The package manager opens but behaves inconsistently after Store, App Installer, or servicing issues.
How the command sequence works
The sequence first checks current package manager information, then resets and refreshes sources, re-registers the App Installer package family, and opens the WinGet logs so you can inspect the exact failure if the repair is incomplete.
When it makes sense to run it
Use it when WinGet itself is broken, not just when one package install failed because of publisher-side or package-specific issues.
Before you run this command
- Open the shell that matches winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs before you paste it.
- Confirm that the symptom really matches this guide, especially if you are seeing signs such as: winget cannot find packages it should normally find.
- Identify the exact Windows component that is failing before you use winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs, so you do not reset unrelated parts of the system.
What result to expect
After running winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs, compare the result against the symptom that brought you here. The most useful checkpoint is whether winget cannot find packages it should normally find becomes less frequent, changes form, or produces a clearer error message. A command page is stronger when it helps you verify a real change instead of just assuming the line must have worked.
How to verify that it worked
The best verification step after winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs is to repeat the action that previously triggered the problem. If source updates fail or return unexpected errors still appears in exactly the same way, the command probably was not the whole answer and you should move to the next targeted check instead of assuming the page is finished.
Shell and execution context
This command usually does not need a full elevated repair context, but it still works best when you run it in the shell it was written for and read the output carefully.
Before you run it
Run PowerShell as administrator for the package re-registration step. If WinGet is blocked by policy or a damaged Store platform, you may need to repair the underlying AppX or Store environment too.
When this is probably the wrong fix
This is not the right first fix for every generic crash. Use it when the failing part is a Windows service, built-in app package, indexing component, print queue, audio stack, or similar subsystem.
What to do if it does not help
If winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs does not improve winget cannot find packages it should normally find, move to the next repair step that matches the same symptom family instead of piling on random commands. The best follow-up depends on whether the failure is mainly about a Windows service, package, or built-in app component.
Frequently asked questions
Should I use winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs for this exact Windows symptom?
Use it when the behavior on your PC lines up with the repair target on this page: It targets a broken or unstable Windows Package Manager setup where winget commands fail, show source errors, or behave inconsistently.
What should I check right after winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs?
Check whether the original trigger still reproduces the same failure. For this page, a useful checkpoint is whether winget cannot find packages it should normally find becomes less frequent, changes form, or points you toward a more specific next step.
When should I not rely on winget --info winget source reset --force winget source update Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe winget --open-logs alone?
This is not the right first fix for every generic crash. Use it when the failing part is a Windows service, built-in app package, indexing component, print queue, audio stack, or similar subsystem.