Professional Documents
Culture Documents
App Packager (MakeAppx - Exe) - Win32 Apps - Microsoft Learn
App Packager (MakeAppx - Exe) - Win32 Apps - Microsoft Learn
7 Note
For UWP guidance on using this tool, see Create an app package with the
MakeAppx.exe tool.
App packager (MakeAppx.exe) creates an app package from files on disk or extracts the
files from an app package to disk. Starting with Windows 8.1, App packager also creates an
app package bundle from app packages on disk or extracts the app packages from an app
package bundle to disk. It is included in Microsoft Visual Studio and the Windows Software
Development Kit (SDK) for Windows 8 or Windows Software Development Kit (SDK) for
Windows 8.1 and newer. Visit Downloads for developers to get them.
The MakeAppx.exe tool is typically found in operating system version specific locations:
Where = x86, x64, arm, ar64 or chpe. Alternatively, it may be located in:
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 1/9
5/16/23, 9:50 PM App packager (MakeAppx.exe) - Win32 apps | Microsoft Learn
7 Note
2. Create a valid package manifest, AppxManifest.xml, and place it in the root directory.
2. Create a mapping file. The first line contains the string [Files], and the lines that follow
specify the source (disk) and destination (package) paths in quoted strings.
syntax
[Files]
"C:\MyApp\StartPage.htm" "default.html"
"C:\MyApp\readme.txt" "doc\readme.txt"
"\\MyServer\path\icon.png" "icon.png"
"MyCustomManifest.xml" "AppxManifest.xml"
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 2/9
5/16/23, 9:50 PM App packager (MakeAppx.exe) - Win32 apps | Microsoft Learn
The hashAlgorithm must match the hash algorithm used to create the blockmap when
the app was packaged. With the MakeAppx packaging utility, the default Appx
blockmap hash algorithm is SHA256. Run SignTool.exe specifying SHA256 as the file
digest (/fd) algorithm:
For more info about how to sign packages, see How to sign an app package using
SignTool.
2. The unpacked package has the same structure as the installed package.
We use the bundle command to create an app bundle at <output bundle name> by
adding all packages from a list of packages within <mapping file>. If <mapping file>
contains a bundle manifest, AppxBundleManifest.xml, it is ignored.
1. Create a <mapping file>. The first line contains the string [Files], and the lines that
follow specify the packages to add to the bundle. Each package is described by a pair
of paths in quotation marks, separated by spaces or tabs. The pair of paths represents
the package's source (on disk) and destination (in bundle). All destination package
names must have the .appx extension.
syntax
[Files]
"C:\MyApp\MyApp_x86.appx" "MyApp_x86.appx"
"C:\Program Files (x86)\ResPack.appx" "resources\resPack.appx"
"\\MyServer\path\ResPack.appx" "Respack.appx"
"my app files\respack.appx" "my app files\respack.appx"
2. The unpacked bundle has the same structure as the installed package bundle.
syntax
[Keys]
"0"
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 4/9
5/16/23, 9:50 PM App packager (MakeAppx.exe) - Win32 apps | Microsoft Learn
"1AC4CDCFF1924D2885A0607269787BA6BF09B7FFEBF74ED4B9D86E423CF9186B"
3. The input package will be encrypted into the specified encrypted package using the
provided key file.
2. The input package will be encrypted into the specified encrypted package using the
global test key.
syntax
[Keys]
"OWVwSzliRGY1VWt1ODk4N1Q4R2Vqc04zMzIzNnlUREU="
"MjNFTlFhZGRGZEY2YnVxMTBocjd6THdOdk9pZkpvelc="
3. The input package will be decrypted into the specified unencrypted package using
the provided key file.
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 5/9
5/16/23, 9:50 PM App packager (MakeAppx.exe) - Win32 apps | Microsoft Learn
2. The input package will be decrypted into the specified unencrypted package using
the global test key.
Usage
The command line argument /p is always required, with either /d, /f, or /ep. Note that /d,
/f, and /ep are mutually exclusive.
MakeAppx encrypt [options] /p <input package name> /ep <output package name>
MakeAppx decrypt [options] /p <input package name> /ep <output package name>
Command-line Syntax
Here is the command-line common usage syntax for MakeAppx.
MakeAppx packs or unpacks the files in a package, bundles or unbundles the packages in
a bundle, or encrypts or decrypts the app package or bundle in the specified input
directory or mapping file. Here is the list of parameters that apply to MakeAppx pack,
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 6/9
5/16/23, 9:50 PM App packager (MakeAppx.exe) - Win32 apps | Microsoft Learn
/l
This option is used for localized packages. The default validation trips on localized
packages. This option disables only that specific validation, without requiring that all
validation be disabled.
/o
Overwrite the output file if it exists. If you don't specify this option or the /no option, the
user is asked whether they want to overwrite the file.
/no
Prevents an overwrite of the output file if it exists. If you don't specify this option or the /o
option, the user is asked whether they want to overwrite the file.
/nv
Skip semantic validation. If you don't specify this option, the tool performs a full validation
of the package.
/v
/?
Creates a package.
/h algorithm
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 7/9
5/16/23, 9:50 PM App packager (MakeAppx.exe) - Win32 apps | Microsoft Learn
Specifies the hash algorithm to use when creating the block map. Here are valid values for
algorithm:
SHA256 (default)
SHA384
SHA512
Extracts all files in the specified package to the specified output directory. The output has
the same directory structure as the package.
/pfn
Specifies a directory named with the package full name. This directory is created under the
provided output location. You can't use this option with the pack command.
Unpacks all packages to a subdirectory under the specified output path, named after the
bundle full name. The output has the same directory structure as the installed package
bundle.
/pfn
Specifies a directory named with the package bundle full name. This directory is created
under the provided output location. You can't use this option with the bundle command.
Creates an encrypted app package from the specified input app package at the specified
output package.
Encrypts the package or bundle using the key from the specified key file. You can't use this
option with kt.
/kt
Encrypts the package or bundle using the global test key. You can't use this option with kf.
Creates an unencrypted app package from the specified input app package at the specified
output package.
Decrypts the package or bundle using the key from the specified key file. You can't use this
option with kt.
/kt
Decrypts the package or bundle using the global test key. You can't use this option with kf.
All files referenced in the package manifest are included in the app package.
An application does not have two identical keys.
An application does not register for a forbidden protocol from this list: SMB , FILE,
MS-WWA-WEB, MS-WWA.
This semantic validation is not complete, and packages built by MakeAppx are not
guaranteed to be installable.
https://learn.microsoft.com/en-us/windows/win32/appxpkg/make-appx-package--makeappx-exe- 9/9