Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Bicep Cost EstimatorNew to Visual Studio Code? Get it now.
Bicep Cost Estimator

Bicep Cost Estimator

Engin Polat

| (0) | Free
Estimate monthly Azure costs from Bicep files
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Bicep Cost Estimator

CodeQL Deploy Website Release BCE CLI BCE CLI version

Bicep Cost Estimator estimates monthly Azure costs from Bicep and ARM templates before you deploy. The published CLI command is bce.

It currently ships as:

  • a .NET CLI
  • a VS Code extension backed by the CLI in LSP mode
  • a GitHub Action for CI and pull request workflows
  • a Docusaurus documentation site with browser and plain-text routes

Quick Start

Install the published CLI:

curl -sL https://bicepcostestimator.net/install.sh | bash
bce estimate --file path/to/main.bicep

The installer uses ~/.local/bin on Linux, /usr/local/bin on Intel macOS, and /opt/homebrew/bin on Apple Silicon by default. Set INSTALL_DIR to override that choice. If the install directory is not on PATH, the installer prints the export PATH=... command to run.

Run via Docker instead, without installing the CLI binary locally:

bce() {
  docker run --rm \
    -v "$PWD:/work" \
    -w /work \
    -v "$HOME/.bicep-cost-estimator:/root/.bicep-cost-estimator" \
    --entrypoint /app/bin/bce \
    ghcr.io/polatengin/washington:latest \
    "$@"
}

Add that function to ~/.bashrc or ~/.zshrc, reload your shell, and then use bce like a normal command:

bce estimate --file ./main.bicep --output json

The wrapper works by starting the published website container, overriding the default startup command so it runs /app/bin/bce instead of the docs server, mounting your current working directory at /work so relative --file and --params-file paths keep working, and mounting ~/.bicep-cost-estimator so the pricing cache persists across runs. Docker is the only local dependency; the image is pulled automatically on first use.

Build from source instead:

git clone https://github.com/polatengin/washington.git
cd washington
make setup-cli
make build-cli
./src/cli/bin/Release/net10.0/bce estimate --file ./tests/fixtures/simple-vm.bicep

What It Does

  • Compiles Bicep to ARM JSON through the Bicep CLI via the Azure.Bicep.RpcClient package
  • Extracts nested resources, copy loops, and conditionally skipped resources
  • Maps 87 Azure resource types to Azure Retail Prices API queries
  • Queries pricing with pagination, retry, and a local 24-hour file cache
  • Renders results as table, json, csv, or markdown

Documentation

  • Introduction
  • Getting Started
  • CLI Commands
  • VS Code Extension
  • GitHub Action
  • How Estimates Work
  • Supported Resources
  • Troubleshooting

Current Limitations

  • Unsupported resource types are skipped with a warning.
  • Spot and low-priority prices are excluded from default estimates.

Development

Common local workflows:

make setup-cli
make test-cli

make setup-extension
make build-extension

make setup-website
make build-website
make dev-website

make setup-cli restores the .NET dependencies needed for the CLI and tests. bce resolves the Bicep CLI at runtime through the Azure.Bicep.RpcClient nuget package.

Roadmap

The roadmap lives in docs/70-roadmap.md and on the documentation site at bicepcostestimator.net/roadmap.

License

MIT

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft