HashiCorp's official Terraform MCP server integrates with the public Terraform Registry and HCP Terraform/Terraform Enterprise APIs. Agents can look up providers, modules and policies, and manage organizations, workspaces, runs and variables. It runs via Docker over stdio or Streamable HTTP.
Connect
- 1Add the server to Codex
codex mcp add terraform --env TFE_TOKEN=YOUR_TFE_TOKEN --env TFE_ADDRESS=YOUR_TFE_ADDRESS -- docker run -i --rm -e TFE_TOKEN -e TFE_ADDRESS hashicorp/terraform-mcp-server
Configs are generated from the publisher's documented endpoint. Check their docs for plan requirements and scopes. New to this? Read the step-by-step tutorial.
Tools 12
search_providersget_provider_detailsget_provider_capabilitiesget_latest_provider_versionsearch_modulesget_module_detailsget_latest_module_versionsearch_policiesget_policy_detailslist_terraform_orgslist_terraform_projectslist_workspacesThings to ask
- “What's the latest version of the AWS provider?”
- “Find a Terraform module for an EKS cluster”
- “Show the arguments for the google_compute_instance resource”
- “List workspaces in my HCP Terraform organization”