Quick verdict
Terraform Cloud's built-in cost estimation is fine for teams already paying for Team tier ($20/user/month) and only needing basic AWS/Azure/GCP coverage. C3X covers more resources, runs anywhere (including offline), supports OpenTofu and Terragrunt, and is free. For teams not already on TFC Team tier, C3X is a strict upgrade.
Terraform Cloud's cost estimation in context
HashiCorp added cost estimation to Terraform Cloud (now HCP Terraform) as a Team/Business tier feature. After terraform plan runs, TFC computes an estimated monthly cost delta and displays it in the plan output.
The feature has merit but has well-documented limitations:
- Resource coverage is partial: many common resources fall back to "$0/month estimated"
- Pricing data is updated periodically, not in real-time
- Requires the Team tier of TFC (additional per-user cost)
- Available only inside TFC — not in CI, not in a CLI
- No offline mode, no air-gapped support
- OpenTofu users can't access this feature at all
Where TFC cost estimation wins
- Already integrated: If you use TFC and the Team tier already, cost estimation appears with no setup. Zero friction.
- Native plan output: Cost data appears alongside terraform plan output in the same UI.
- HashiCorp-maintained: For teams that prefer a single-vendor stack, having TFC handle this means one less tool to evaluate.
Where C3X wins
- Resource coverage: C3X supports 80+ Terraform resources across AWS/Azure/GCP with detailed pricing dimensions. TFC's coverage is documented in their feature list and is notably narrower.
- Runs anywhere: C3X is a CLI you can use in GitHub Actions, GitLab CI, Bitbucket, Atlantis, Spacelift, local dev, or anywhere else. TFC cost estimation only runs in TFC.
- Offline / air-gapped: Critical for GovCloud, IL5/IL6, regulated industries. TFC requires the SaaS endpoint.
- OpenTofu support: Post-BSL license change, many orgs moved to OpenTofu. C3X works identically with both.
- Terragrunt support: Native Terragrunt integration.
- Cost recommendations: C3X suggests right-sizing, gp2-to-gp3, Spot conversions. TFC just shows the estimate.
- Free: Apache 2.0, no per-user fees.
- Self-hostable pricing API: For teams that want to control the pricing data fully.
Feature comparison
| Feature | C3X | TFC Cost Estimation |
|---|---|---|
| Resources supported | 80+ | ~30 (varies) |
| Pricing data freshness | Live (API) | Updated periodically |
| CI integration | Any CI | TFC only |
| Offline mode | Yes | No |
| OpenTofu support | Yes | No |
| Terragrunt support | Yes | Limited |
| CloudFormation support | Yes | No |
| Cost recommendations | Yes | No |
| Budget gating in CI | Yes | Via Sentinel (Business tier) |
| Free tier | Full features | TFC Free has no estimation |
| Annual cost | $0 | $20/user/month (Team tier) |
| License | Apache 2.0 | Proprietary |
Using C3X with Terraform Cloud
If you use TFC for state and plan execution, you can still use C3X as a separate CI step. Common pattern:
# .github/workflows/terraform.yml
jobs:
terraform:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: c3xdev/c3x-action@v1
- name: Estimate cost delta
run: c3x estimate --diff --format=github-comment > c3x.md
- name: Comment cost on PR
uses: actions/github-script@v7
with:
script: |
const fs = require('fs');
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: fs.readFileSync('c3x.md', 'utf8')
});
- name: Run Terraform plan via TFC
uses: hashicorp/tfc-workflows-github/actions/create-run@v1C3X comments cost delta on the PR. TFC continues to handle state, plan execution, and apply. The two work together without conflict.
When to use which
Use C3X: You want broad resource coverage. You use OpenTofu or Terragrunt. You need offline mode. You're on TFC Free or HCP Free and need cost estimation. You want cost recommendations alongside estimates.
Use TFC's built-in: You're already paying for Team tier and only need basic coverage. You prefer a single-vendor stack. You don't need offline or OpenTofu support.
FAQ
What is Terraform Cloud's built-in cost estimation?
Terraform Cloud (and HCP Terraform) includes a cost estimation feature that runs after terraform plan, showing estimated monthly cost change. It covers a subset of AWS, Azure, and GCP resources. The feature is available on Team and Business tiers of TFC/HCP — not on the free or Standard tiers.
Why use C3X instead of TFC's built-in estimation?
Three main reasons. (1) Service coverage: C3X supports more resources than TFC. (2) Offline mode: TFC requires its SaaS; C3X runs anywhere including air-gapped environments. (3) Cost: TFC cost estimation requires Team ($20/user/month) or Business tier; C3X is free.
Can I use C3X with Terraform Cloud workspaces?
Yes. C3X runs as a separate step in the CI workflow before or after terraform plan. It reads the Terraform configuration directly (no need to access TFC's state). For teams using TFC, this means estimation happens in your CI pipeline rather than via TFC's plan step.
What about OpenTofu?
C3X supports OpenTofu identically to Terraform — same HCL parser, same plan format. For teams that migrated to OpenTofu post-license change, C3X is a natural fit. OpenTofu doesn't have built-in cost estimation, so C3X fills that gap.
Does C3X work with Terragrunt?
Yes. C3X handles Terragrunt's HCL-with-imports configuration. Run c3x estimate at the root or in a specific Terragrunt module. Output is the same as plain Terraform.