Skip to content
ENExplore Calculators

Terraform Infrastructure Score Calculator

Generate a quality score for a Terraform codebase from structure, drift and coverage.

About Terraform Infrastructure Score Calculator

Infrastructure score blends four weighted signals: drift (30%, penalizing resources that diverge from state), plan/apply success rate (30%, reliability of the core workflow), apply time (15%, operational efficiency), and module reuse (25%, a proxy for consistency and maintainability). Each is normalized to 0-100 before weighting, mirroring the structure of the Git repository health score for a comparable DevOps maturity view.

Formula

score = drift_score × 0.30 + success_score × 0.30 + apply_time_score × 0.15 + reuse_score × 0.25

drift_score
clamp(100 - drift_percent × 2, 0, 100)
success_score
Plan/apply success rate percentage
apply_time_score
clamp(100 - (avg_apply_min - 1) / 29 × 100, 0, 100)
reuse_score
Module reuse percentage

Worked example

With the default values below, Terraform Infrastructure Score Calculator returns Infrastructure Score of 82.7. Change any input above and every figure here is recalculated in your browser.

Inputs used

Infrastructure Driftaccepts 0–100 %
6 %
Plan/Apply Success Rateaccepts 0–100 %
92 %
Avg Apply Timeaccepts 0–100,000 minutes
6 minutes
Module Reuseaccepts 0–100 %
65 %

Results

Infrastructure Score
82.7 /100
Grade
Good
Drift Score
88 /100
Plan Success Score
92 /100
Apply Time Score
83 /100
Module Reuse Score
65 /100

Step by step

  1. 1Drift score (30%)= 88
  2. 2Plan success score (30%)= 92
  3. 3Apply time score (15%)= 83
  4. 4Module reuse score (25%)= 65
  5. 5Weighted infrastructure score= 82.7

Assumptions and limits

  • The result is derived only from the 4 inputs listed above. Anything not among them is not part of the calculation.
  • In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
  • Figures are rounded for display to 1 decimal place, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.

How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.

Frequently Asked Questions

Why do drift and success rate carry equal, highest weight?

Both directly reflect whether your infrastructure-as-code can be trusted as the source of truth — high drift means your code lies about reality, and low success rate means the core workflow (plan/apply) itself is unreliable, undermining confidence in every other metric.

How is module reuse measured in practice?

Divide resources provisioned through calls to shared/versioned modules by total managed resources — a high ratio indicates standardized, DRY infrastructure patterns rather than repeated inline resource blocks per environment.

Can a fast-applying configuration still score poorly overall?

Yes — apply time only carries 15% weight, so a fast but heavily drifted or unreliable (low success rate) configuration will still score low overall, correctly reflecting that speed doesn't offset trustworthiness issues.

How should I act on a low infrastructure score?

Start with whichever sub-score is lowest: schedule drift remediation if drift is high, investigate flaky providers/modules if success rate is low, or invest in a shared module library if reuse is low.

Terraform Infrastructure Score Calculator | Calcrivo