Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Cloud Cost Lens (Terraform + CloudFormation)New to Visual Studio Code? Get it now.
Cloud Cost Lens (Terraform + CloudFormation)

Cloud Cost Lens (Terraform + CloudFormation)

Vahmoh111

|
24 installs
| (1) | Free
Inline cloud cost estimates for Terraform and CloudFormation files using your own pricing. See per‑resource and file totals as you type, with CodeLens, inline hints, a status bar total, and a side panel breakdown. Works fully offline with JSON/YAML price configs, supports overlays and environments,
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Cloud Cost Calculator (VS Code Extension)

Stop AWS bill shock! See cloud costs instantly as you code. Save thousands monthly.

Real-time cloud infrastructure cost estimates for IaC files (Terraform, CloudFormation). Bring your own prices (JSON/YAML). Inline hints, CodeLens, status bar, and a side panel breakdown.

Features

  • Price config: .cloudcost/prices.json or .yaml (workspace) and ~/.cloudcost/prices.json (global)
  • Terraform (.tf, .tf.json) and CloudFormation (YAML/JSON) parsing
  • Inline monthly costs, detailed CodeLens, status bar total
  • Side panel with totals and per-category breakdown
  • Export cost report (JSON)
  • Environments and overlays: cloudcost.environment and cloudcost.files.additionalPriceConfigs
  • 3-day trial, one-time license (€9) for perpetual use

Quick Start

  1. Create a price file in your workspace, e.g. .cloudcost/prices.json (see below).
  2. Open a Terraform/CloudFormation file; inline hints appear.
  3. Use the Command Palette (Ctrl+Shift+P):
    • Cloud Cost: Calculate Total
    • Cloud Cost: Toggle Display
    • Cloud Cost: Show Cost Breakdown
    • Cloud Cost: Export Cost Report
    • Cloud Cost: Enter License Key / Purchase Info

Example prices.json:

{
  "version": "1.0",
  "currency": "USD",
  "provider": "AWS",
  "region": "us-east-1",
  "resources": {
    "compute": { "t3.micro": { "hourly": 0.0104, "monthly": 7.488 } },
    "storage": { "gp3": { "per_gb_monthly": 0.08 } }
  }
}

Price Configuration Format

  • version: string (config version)
  • currency: string (e.g., USD)
  • provider: string (e.g., AWS)
  • region: string (e.g., us-east-1)
  • resources: map of categories, each a map of SKUs with price entries
    • compute: { "": { hourly?, monthly?, yearly? } }
    • database: { "": { hourly?, monthly? } }
    • storage: { "": { per_gb_monthly?, iops?, throughput? } }
    • network: { "": { hourly?, monthly?, per_gb_processed? } }

Example (YAML):

version: "1.0"
currency: USD
provider: AWS
region: us-east-1
resources:
  compute:
    t3.small:
      hourly: 0.0208
      monthly: 14.976
  storage:
    gp3:
      per_gb_monthly: 0.08

Settings

  • cloudcost.display.format: minimal | detailed | breakdown
  • cloudcost.display.colorThresholds: low/medium/high monthly thresholds
  • cloudcost.calculation.hoursPerMonth: default 730
  • cloudcost.files.priceConfig: default .cloudcost/prices.json
  • cloudcost.files.additionalPriceConfigs: array of overlay files
  • cloudcost.environment: default | dev | staging | prod

Licensing

  • Trial: 3 days from first activation.
  • One-time price: €9 for a perpetual license.
  • Purchase: Visit https://mohawk6015.gumroad.com/l/dgljh to purchase your license key instantly.
  • Enter key: run “Cloud Cost: Enter License Key”.

Perpetual key format is a single hash string issued by the author.

Test Workspace

Use the included test-environment folder containing sample IaC files and ready-to-use price configs.

Screenshots

Inline costs

Side panel breakdown

Inline costs 2

Sidebar

CLI

Run the CLI to generate a cost report:

npx cloudcost ./test-environment ./test-environment/.cloudcost/prices.json

Changelog

See CHANGELOG.md.

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