hash command (winget)

July 21, 2025 ยท View on GitHub

The hash command of the winget tool generates the SHA256 hash for an installer. This command is used if you need to create a manifest file for submitting software to the Microsoft Community Package Manifest Repository on GitHub.

winget hash command

In addition, the hash command also supports generating a SHA256 certificate hash for MSIX files.

winget hash msix command

Usage

winget hash [--file] <file> [<options>]

The hash sub-command can only run on a local file. To use the hash sub-command, download your installer to a known location. Then pass in the file path as an argument to the hash sub-command.

winget hash command help options

Arguments

The following arguments are available:

ArgumentDescription
-f,--fileThe path to the file to be hashed.

Options

The options allow you to customize the hash experience to meet your needs.

OptionDescription
-m,--msixSpecifies that the hash command will also create the SHA-256 SignatureSha256 for use with MSIX installers.
-?, --helpGets additional help on this command.
--waitPrompts the user to press any key before exiting.
--logs,--open-logsOpen the default logs location.
--verbose, --verbose-logsUsed to override the logging setting and create a verbose log.
--nowarn,--ignore-warningsSuppresses warning outputs.
--disable-interactivityDisable interactive prompts.
--proxySet a proxy to use for this execution.
--no-proxyDisable the use of proxy for this execution.