Infracost VS Code ExtensionInfracost's VS Code extension shows you cost estimates for Terraform right in your editor! It also surfaces FinOps policies and tagging issues so you can catch problems before they reach production. Table of contentsFeaturesCost estimatesInline cost estimatesSee cost estimates as code lenses directly above Terraform resource definitions. Costs update as you edit.
Resource details sidebarClick a code lens to open the resource details panel, showing a full cost component breakdown, FinOps policy violations, and tagging issues.
FinOps policies and tag issuesThe extension highlights FinOps policy violations (with risk, effort, and potential savings) and tag policy issues directly in the sidebar. Blocking violations are clearly marked.
CloudFormation supportIn addition to Terraform ( Get started
1. Install the extensionOpen VS Code and go to the Extensions view ( Alternatively, use the Quick Open command:
Installing a pre-release versionDownload the
Or in VS Code: open the Command Palette (
2. Login to InfracostOpen the Infracost sidebar and click Login to Infracost. This will open a browser window to authenticate your editor with your Infracost account.
3. Open a Terraform projectOpen a workspace containing Terraform files. The extension will start the language server and begin scanning your project. Cost estimates will appear as code lenses above resource blocks. 4. Cost estimates in pull requestsUse our CI/CD integrations to add cost estimates to pull requests, giving your team visibility into cloud costs as part of your workflow. Requirements
Configuration
Commands
TroubleshootingLocating logs
If you're having issues, please start a thread in GitHub Discussions with as much log information as you can, along with your OS and VS Code version. ContributingWe welcome contributions! Please start by opening a thread in GitHub Discussions to discuss your idea before submitting a PR. To set up a local development environment:
|



