Installing Bicep
Every way to get the Bicep CLI onto Windows and macOS, which one to pick, and how to confirm it's actually working.
There are more ways to install Bicep than most people realise, and which one you want depends on how you plan to deploy. Run bicep --version any time to confirm what you’ve got, and bicep upgrade to update in place (only works for CLI installs you manage yourself, more on that below).
Windows
Via Azure CLI (automatic)
If you’ve got the Azure CLI installed (version 2.20.0 or later), you already have everything you need. Bicep installs itself the first time you run a command that needs it:
az bicep versionThis installs a self-contained copy of Bicep that Azure CLI manages for you. It doesn’t get added to your PATH, and it won’t conflict with any of the manual installs below.
Via winget
The quickest manual install, and the one I’d default to on Windows 11 or a current Windows 10 box:
winget install -e --id Microsoft.BicepVia the Windows installer
Download and run the latest Windows installer directly. It doesn’t need administrative privileges, and it adds Bicep to your user PATH automatically. Close and reopen any open terminal windows afterwards for the PATH change to take effect.
Via Chocolatey
choco install bicepManual install with PowerShell
For full control over where it lands:
# Create the install folder
$installPath = "$env:USERPROFILE\.bicep"
$installDir = New-Item -ItemType Directory -Path $installPath -Force
$installDir.Attributes += 'Hidden'
# Fetch the latest Bicep CLI binary
(New-Object Net.WebClient).DownloadFile("https://github.com/Azure/bicep/releases/latest/download/bicep-win-x64.exe", "$installPath\bicep.exe")
# Add bicep to your PATH
$currentPath = (Get-Item -path "HKCU:\Environment").GetValue('Path', '', 'DoNotExpandEnvironmentNames')
if (-not $currentPath.Contains("%USERPROFILE%\.bicep")) { setx PATH ($currentPath + ";%USERPROFILE%\.bicep") }
if (-not $env:path.Contains($installPath)) { $env:path += ";$installPath" }
bicep --helpmacOS
Via Azure CLI (automatic)
Same story as Windows: if you’re on Azure CLI 2.20.0 or later, running a command that needs Bicep installs it for you.
az bicep versionVia Homebrew
The standard route on Mac:
brew tap azure/bicep
brew install bicepManual install with bash
# Fetch the latest Bicep CLI binary
curl -Lo bicep https://github.com/Azure/bicep/releases/latest/download/bicep-osx-x64
# Mark it as executable
chmod +x ./bicep
# Add Gatekeeper exception (requires admin)
sudo spctl --add ./bicep
# Add bicep to your PATH (requires admin)
sudo mv ./bicep /usr/local/bin/bicep
bicep --helpThe Gatekeeper exception step is only needed on Bicep CLI versions older than 0.16.x, current installs shouldn’t require it, but it’s harmless to include if you hit a “can’t be opened” warning.
Verify it’s working
Whichever method you used, confirm it from a fresh terminal window:
bicep --versionIf you installed via Azure CLI instead of standalone, check it the Azure CLI way:
az bicep versionVS Code and the Bicep extension
Whichever OS you’re on, install the Bicep extension for VS Code for syntax highlighting, IntelliSense and validation against the real Azure resource provider schemas while you write. Search “bicep” in the Extensions tab, or from the command line:
code --install-extension ms-azuretools.vscode-bicepOpen any .bicep file afterwards and check the language mode in the bottom-right corner reads Bicep to confirm it’s active.
Official docs
Microsoft’s own install guide covers Linux, air-gapped environments and nightly builds too: Install Bicep tools.