Free ยท Lesson 1 of 12

Meet Terraform and OpenTofu

Terraform and OpenTofu both read HCL and both keep a state file. They are not one product with two names.

Sign in to save your place.

Picture it this way

You write a shopping list for servers and databases. The tool goes to the shop and tries to make the shop match the list. Terraform is HashiCorp's list-runner. OpenTofu is a separate list-runner that started from an older public copy of the same idea.

Infrastructure as code

A Terraform configuration describes resources. terraform plan prints what would change. terraform apply asks the providers to make those changes and writes the result into a state file. The state file is how the next plan knows which real object belongs to which block.

The tool does not invent your cloud account. A provider plugin talks to AWS, Azure, Google Cloud, or something else. No provider, no resources.

Two projects after 2023

HashiCorp changed the Terraform license to the Business Source License on 10 August 2023. OpenTofu is a Linux Foundation project under the Mozilla Public License 2.0. It was forked from the Terraform codebase that was still under that public license.

The commands look alike because of that history. terraform plan and tofu plan are not a contract that every later feature exists in both, or that a HashiCorp cloud product will run the OpenTofu binary. The security lesson compares them without calling them equivalent.

Name Who publishes it Do not assume
Terraform HashiCorp That OpenTofu has the same license
OpenTofu The OpenTofu project, under the Linux Foundation That HCP Terraform runs it
HCP Terraform HashiCorp's hosted product, formerly Terraform Cloud That it is an OpenTofu control plane

List, plan, reality

  1. HCL
  2. Plan
  3. Cloud

Step 1 of 3The configuration is the list. It is not the cloud.

Lab: say which binary you mean

You may not have either tool installed yet. Write the sentence anyway. The next lesson installs one on purpose.

I will install: terraform OR tofu (pick one for this week).
I will not call the other one a drop-in replacement.
HCP Terraform is a HashiCorp service. It is not OpenTofu.

Concept summary

Knowledge check

What does a plan do?

Which statement is fair?

Why does the next plan need a state file?

Official sources

Checked against the linked documentation in October 2026. A later release can move a flag, a price, or a supported pair. Use the page for the version you installed.