WinappCli
winapp, the Windows App Development CLI, is a single command-line interface for managing Windows SDKs, packaging, generating app identity, manifests, certificates, and using build tools with any app framework.
Install / Use
/learn @microsoft/WinappCliREADME
winapp CLI
<p align="center"> <picture> <img src="./docs/images/winapp-terminal.png"> </picture> </p> <br/> <p align="center"> <img src="https://img.shields.io/winget/v/Microsoft.WinAppCli?style=for-the-badge&logo=windows&color=357EC7" alt="WinGet"> <a href="https://www.npmjs.com/package/@microsoft/winappcli"> <img src="https://img.shields.io/npm/v/%40microsoft%2Fwinappcli?style=for-the-badge&logo=npm" alt="NPM"> </a> <a href="https://github.com/microsoft/WinAppCli/releases/latest"> <img src="https://img.shields.io/github/v/release/microsoft/WinAppCli?style=for-the-badge&logo=github&label=Latest%20Release&color=8ab4f8" alt="Latest Release"> </a> <br /> <a href="https://github.com/microsoft/WinAppCli/issues"> <img src="https://img.shields.io/github/issues/microsoft/WinAppCli?style=for-the-badge&logo=github&color=81c995" alt="Issues"> </a> <a href="https://github.com/microsoft/WinAppCli/blob/main/LICENSE"> <img alt="GitHub License" src="https://img.shields.io/github/license/microsoft/winappcli?style=for-the-badge"> </a> <br /> </p> <h3 align="center"> <a href="#-why-package-identity">Why?</a> <span> • </span> <a href="#%EF%B8%8F-get-started">Get Started</a> <span> • </span> <a href="#-installation">Installation</a> <span> • </span> <a href="#-usage">Usage</a> <span> • </span> <a href="./docs/usage.md">Docs</a> <span> • </span> <a href="#-feedback-and-support">Feedback</a> </h3> <br/>[!IMPORTANT] :warning: Status: Public Preview - The Windows App Development CLI (winapp CLI) is experimental and in active development. We'd love your feedback! Share your thoughts by creating an issue.
The Windows App Development CLI (winapp CLI) is a single command-line interface for managing Windows SDKs, packaging, generating app identity, manifests, certificates, and using build tools with any app framework. This tool bridges the gap between cross-platform development and Windows-native capabilities. <br/><br/> Whether you're building with .NET/Win32, CMake, Electron, or Rust, this CLI gives you access to:
- Modern Windows APIs - Windows App SDK and Windows SDK with automatic setup and code generation
- Package Identity - Debug and test by adding package identity without full packaging in a snap
- MSIX Packaging - App packaging with signing and Store readiness
- Developer Tools - Manifests, certificates, assets, and build integration
Perfect for:
- Cross-platform developers using frameworks like Qt or Electron wanting native Windows features or targeting Windows
- Developers who love their current tools and want to build Windows apps from VS Code, or any other editor
- Developers crafting CI/CD pipelines to automate building apps for Windows
🤔 Why?
Many powerful Windows APIs require your app to have package identity, enabling you to leverage some of the OS components Windows offers, that you wouldn't otherwise have access to. With identity, your app gains access to user-first features like notifications, OS integration, and on-device AI.
Our goal is to support developers wherever they are, with the tools and frameworks they already use. Based on feedback from developers shipping cross-platform apps on Windows, we built this CLI to streamline integrating with the Windows developer platform - handling SDK setup, header generation, manifests, certificates, and packaging in just a few commands:
<p align="center"> <picture> <source media="(prefers-color-scheme: dark)" srcset="./docs/images/before-after-winapp-dark.png"> <source media="(prefers-color-scheme: light)" srcset="./docs/images/before-after-winapp.png"> <img src="./docs/images/before-after-winapp.png" alt="Before: 12 manual steps to access Windows APIs. After: 4 winapp commands (init, create-addon, add-electron-debug-identity, pack)"> </picture> </p> <p align="center"><i>Without winapp CLI, setting up a project involves 12 manual steps—downloading SDKs, generating headers, creating manifests, and more. With the CLI, it's just 4 commands.</i></p>Few examples of what package identity and MSIX packaging unlocks:
- Interactive native notifications and notification management
- Integration with Windows Explorer, Taskbar, Share sheet, and other shell surfaces
- Protocol handlers (
yourapp://URIs) - Web-to-app linking (
yoursite.comopens your app) - On-device AI (Local LLM, Text and Image AI APIs)
- Custom CLI commands via AppExecutionAlias
- Controlled access to camera, microphone, location, and other devices (with user consent)
- Background tasks (run when app is closed)
- File type associations (open
.xyzfiles with your app) - Startup tasks (launch at Windows login)
- App services (expose APIs to other apps)
- Clean install/uninstall & auto-updates
✏️ Get started
Checkout our getting started guides for step by step instructions of how to setup your environment, generate manifests, assets, and certificate, how to debug APIs that require package identity, and how to MSIX package your app.
<p> <a href="./docs/guides/dotnet.md"> <img src="https://img.shields.io/badge/.NET/WPF/WinForms-Get%20Started-512BD4?style=for-the-badge&logo=dotnet&logoColor=white" alt="Get Started with .NET"> </a> <br /> <a href="./docs/guides/cpp.md"> <img src="https://img.shields.io/badge/C++-Get%20Started-00599C?style=for-the-badge&logo=cplusplus&logoColor=white" alt="Get Started with C++"> </a> <br /> <a href="/docs/electron-get-started.md"> <img src="https://img.shields.io/badge/Electron-Get%20Started-47848F?style=for-the-badge&logo=electron&logoColor=white" alt="Get Started with Electron"> </a> <br /> <a href="./docs/guides/rust.md"> <img src="https://img.shields.io/badge/Rust-Get%20Started-000000?style=for-the-badge&logo=rust&logoColor=white" alt="Get Started with Rust"> </a> <br /> <a href="/docs/guides/tauri.md"> <img src="https://img.shields.io/badge/Tauri-Get%20Started-FFC131?style=for-the-badge&logo=tauri&logoColor=black" alt="Get Started with Tauri"> </a> <br /> <a href="./docs/guides/flutter.md"> <img src="https://img.shields.io/badge/Flutter-Get%20Started-02569B?style=for-the-badge&logo=flutter&logoColor=white" alt="Get Started with Flutter"> </a> </p>Additional guides:
- Packaging an EXE/CLI: step by step guide of packaging an existing exe/cli as MSIX
📦 Installation
WinGet <img src="https://img.shields.io/winget/v/Microsoft.WinAppCli?style=for-the-badge&logo=windows&color=357EC7" alt="WinGet" height="24">
The easiest way to use the CLI is via WinGet (Windows Package Manager). In Terminal, simply run:
winget install Microsoft.winappcli --source winget
NPM <a href="https://www.npmjs.com/package/@microsoft/winappcli"> <img src="https://img.shields.io/npm/v/%40microsoft%2Fwinappcli?style=for-the-badge&logo=npm" alt="NPM" height="24"></a>
You can install the CLI for Electron projects via NPM:
npm install @microsoft/winappcli --save-dev
GitHub Actions / Azure DevOps
For CI/CD pipelines on GitHub Actions or Azure DevOps, use the setup-WinAppCli action to automatically install the CLI on your runners/agents.
Download Release Manually
Download the latest build from GitHub Releases
📋 Usage
Once installed (see Installation above), verify the installation by calling the CLI:
winapp --help
or if using Electron/Node.js
npx winapp --help
Commands Overview
Setup Commands:
init- Initialize project with Windows SDK and App SDKrestore- Restore packages and dependenciesupdate- Update packages and dependencies to latest versions
App Identity & Debugging:
package- Create MSIX packages from directoriescreate-debug-identity- Add temporary app identity for debuggingmanifest- Generate and manage AppxManifest.xml files
Certificates & Signing:
cert- Generate and install development certificatessign- Sign MSIX packages and executablescreate-external-catalog- Generate CodeIntegrityExternal.cat for TrustedLaunch sparse packages
Development Tools:
tool- Acces
