Install Azure CLI on Windows
For Windows the Azure CLI is installed via an MSI, which gives you access to the CLI through the Windows Command Prompt (CMD) or PowerShell. When installing for Windows Subsystem for Linux (WSL), packages are available for your Linux distribution. See the main install page for the list of supported package managers or how to install manually under WSL.
Install or update
The MSI distributable is used for installing, updating, and uninstalling the
az command on Windows.
When the installer asks if it can make changes to your computer, click the "Yes" box.
You can now run the Azure CLI with the
az command from either Windows Command Prompt or PowerShell. PowerShell offers some tab completion features
not available from Windows Command Prompt. To sign in, run the az login command.
If the CLI can open your default browser, it will do so and load a sign-in page.
Otherwise, you need to open a browser page and follow the instructions on the command line to enter an authorization code after navigating to https://aka.ms/devicelogin in your browser.
Sign in with your account credentials in the browser.
To learn more about different authentication methods, see Sign in with Azure CLI.
If you decide to uninstall the Azure CLI, we're sorry to see you go. Before you uninstall, use the
az feedback command to let us know
what could be improved or fixed. Our goal is to make the Azure CLI bug-free and user-friendly. If you found a bug, we'd appreciate it if you file a GitHub issue.
Uninstalling can be done by running the MSI again, and choosing the "Uninstall" option.
Now that you've installed the Azure CLI, take a short tour of its features and common commands.