infracost is a free, open source cloud infrastructure management project written in Go and released under Apache-2.0. It has 12,521 GitHub stars, 688 forks and 22 open issues, and was last pushed 8 days ago. On this registry it ranks #13 of 43 tracked projects in Cloud Infrastructure Management, with 5 head-to-head comparisons available. It gained 5 stars over the last 3 tracked days.

What is infracost?

Infracost is an open-source cloud cost intelligence tool, written in Go and licensed Apache-2.0, that estimates cloud spend and enforces FinOps policies for Terraform, Terragrunt, CloudFormation and AWS CDK before changes are deployed β€” built for engineers, platform and DevOps teams, FinOps practitioners, and AI coding agents.

What it is

Infracost is a cost-intelligence layer for infrastructure as code. It reads a Terraform, Terragrunt, CloudFormation or AWS CDK project, produces a resource-level cost breakdown with FinOps recommendations, and surfaces that result in the terminal, in an editor, inside an AI coding agent, and on pull requests. It sits in the Infrastructure & Operations / Cloud Infrastructure Management space and integrates directly into the infrastructure-as-code and CI/CD ecosystem, with support for over 1,100 resources across AWS, Azure and GCP.

The concrete problem it solves is that infrastructure changes are usually merged with no cost signal attached, and the cost only becomes visible after deployment. Infracost replaces that after-the-fact discovery by pricing the change while it is still a diff, in the same place the change is reviewed. A single engine, one pricing dataset and one set of FinOps policies back every entry point, so a check configured once is applied consistently by the CLI, the editor extensions, the agent skills and the pipeline.

Key capabilities

  • infracost scan produces a full cost breakdown and FinOps recommendations for a Terraform, Terragrunt, CloudFormation or AWS CDK project.
  • infracost setup runs an interactive flow that authenticates the user and wires up the editor, AI agent skills and CI/CD in one pass.
  • infracost inspect commands give deeper per-scan detail, including resource-level breakdowns, cost drivers and policy specifics.
  • The infracost/agent-skills repository plugs cost reasoning into Claude Code, Cursor and other AI coding agents through three skills: iac-generation, scan and price-lookup.
  • IDE extensions β€” infracost/vscode-infracost, infracost/jetbrains-infracost, infracost/infracost.nvim and infracost/zed-infracost β€” show cost lenses, inline hints, hover breakdowns and FinOps diagnostics for .tf, .hcl, CloudFormation and AWS CDK files.
  • All editor integrations are powered by the Infracost Language Server (infracost/lsp), a standard LSP server that any LSP-capable editor can use.
  • CI/CD integrations post cost diffs and policy checks directly onto pull requests, and Infracost Cloud provides the dashboard where tagging policies and guardrails are defined once and enforced everywhere.

Who uses it and how

  • Engineers working in Terraform, Terragrunt, CloudFormation or AWS CDK run infracost scan locally to see the cost of a change before committing it.
  • Platform and DevOps teams wire CI/CD integrations so every pull request carries a cost diff and policy result as part of the existing review workflow.
  • Team leads, managers and FinOps practitioners use Infracost Cloud to define tagging policies and guardrails centrally and to track how spending shifts across projects and pull requests.
  • Teams using AI coding agents such as Claude Code and Cursor install the agent skills so generated infrastructure code stays compliant with tagging, region and budget policies.
  • Multi-cloud organisations apply the same checks across AWS, Azure and GCP resources rather than maintaining separate costing practices per provider.

Getting started

Install through a package manager β€” brew install infracost on macOS, choco install infracost on Windows, or the install script on Linux β€” or download the latest release from GitHub Releases. Then run infracost setup to authenticate and connect the entry points, and infracost scan to price a project.

How it compares

No list of paid products that this project replaces is provided, and the facts name no direct alternatives. It stands alone in this registry as a cost-estimation and FinOps policy tool for infrastructure as code.

When to use it β€” and when not to

Adopt it if infrastructure is defined as code in Terraform, Terragrunt, CloudFormation or AWS CDK and cost needs to be visible during review rather than after deployment. The trade-off is breadth of surface: the full toolkit spans a CLI, an LSP server, four editor extensions, an agent-skills repository and a separate SaaS dashboard, so a team wanting everything connected operates several components, and Infracost Cloud is a distinct hosted product from the Apache-2.0 CLI. Teams whose infrastructure is defined by other tools, or who want no hosted component in the loop, are outside what the documented entry points cover.

project readme (upstream, from github) β€” read inline

Cloud cost intelligence for engineers, AI coding agents, and CI/CD.

Infracost shows cloud cost estimates and FinOps best practices for Terraform, Terragrunt, CloudFormation, and AWS CDK β€” before changes are deployed. See costs in your terminal, your editor, your AI coding agent, or right in pull requests.

Docs Docker pulls Community Slack channel tweet

The Infracost Dev toolkit

Infracost meets engineers wherever they work with infrastructure code β€” the terminal, their editor, their AI coding agent, and their CI pipeline. Every entry point talks to the same engine, the same pricing data, and the same FinOps policies, so a check you set up once shows up everywhere.

Get started

1. Install the CLI

macOS (Homebrew):

brew install infracost

Linux:

curl -fsSL https://raw.githubusercontent.com/infracost/cli/master/scripts/install.sh | sh

Windows (Chocolatey):

choco install infracost

Or download the latest release directly from GitHub Releases.

2. Run setup

infracost setup

The interactive setup walks you through authenticating, connecting your editor, configuring AI agent skills, and wiring up CI/CD. It's the fastest way to get every part of the Infracost toolkit working for your team.

Pick the entry points your team needs:

Infracost CLI

infracost/cli is the core of everything. Point it at a Terraform, Terragrunt, CloudFormation, or AWS CDK project to get a full cost breakdown and FinOps recommendations. The interactive setup wires up your editor, AI agent, and CI in one go.

Follow the quick start to install and authenticate, then:

infracost scan

For a deeper dive into a specific scan β€” full resource-level breakdowns, cost drivers, and policy details β€” use the infracost inspect commands.

AI coding agents

infracost/agent-skills plugs Infracost into Claude Code, Cursor, and other AI coding agents so they reason about cloud costs and your FinOps policies as they generate infrastructure code. Three skills ship today:

  • iac-generation β€” keeps generated IaC compliant with your tagging, region, and budget policies
  • scan β€” analyzes an existing project for cost and policy violations
  • price-lookup β€” answers "how much is an m7i.xlarge in us-east-1?" with no existing code needed

IDE extensions

See cost lenses, inline hints, hover breakdowns, and FinOps diagnostics as you edit .tf, .hcl, CloudFormation, and AWS CDK files.

Editor Repo
VS Code, Cursor, Windsurf infracost/vscode-infracost
JetBrains (IntelliJ, GoLand, PyCharm, WebStorm, Rider…) infracost/jetbrains-infracost
Neovim infracost/infracost.nvim
Zed infracost/zed-infracost

All of them are powered by the Infracost Language Server β€” a standard LSP server, so any editor that speaks LSP can integrate with Infracost.

CI/CD

Post cost diffs and policy checks directly on pull requests as part of your existing workflow, use the CI/CD integrations to set this up.

Infracost Cloud

Infracost Cloud is the SaaS dashboard that ties everything together. Team leads, managers, and FinOps practitioners can define tagging policies and guardrails once, and have them enforced consistently across the CLI, the editor extensions, the agent skills, and CI β€” plus get visibility into how spending is shifting across every project and PR.

Supported clouds and resources

Infracost supports over 1,100 resources across AWS, Azure, and Google Cloud, and can estimate usage-based resources such as S3 and Lambda.

About this repo

This repository is the front door to the Infracost project and the best place to follow it β€” star and watch to stay in the loop on releases across the whole ecosystem.

As part of the Infracost 2.0 release, the codebase has been refactored into the focused repositories linked above; some pieces may consolidate back here over time. Issues and discussions for the project as a whole still live here unless a repo-specific tracker is a better fit.

Community

Join our community Slack channel to learn more about cost estimation, Infracost, and to connect with other users and contributors.

If you run into any issues or have feedback, please open a thread in GitHub Discussions.

Thanks to everyone who has contributed β€” bug reports, code, feedback, and ideas all welcome.

License

Apache License 2.0

Frequently asked questions

Is infracost free to use?

infracost is open source under the Apache-2.0 licence. There is no licence fee and no seat count β€” you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does infracost do?

Cloud cost intelligence for engineers, AI coding agents, and CI/CD πŸ’°πŸ“‰ Shift FinOps Left!

What is infracost written in?

infracost is primarily written in Go. Its source is publicly available at https://github.com/infracost/infracost, and it has 12,521 GitHub stars.