talira

Terraform MCP Server

HashiCorp's MCP server for Terraform Registry and HCP Terraform

open sourceMPL-2.0self-hostablefreeMCP

The Terraform MCP Server is HashiCorp's official MCP server, written in Go under MPL-2.0, that connects AI assistants to the Terraform ecosystem. It searches the public Terraform Registry for providers, modules and policies and reads their documentation, so an assistant writes configuration against current provider versions. With an HCP Terraform or Terraform Enterprise token it also lists organizations and projects, reads the private registry, and creates, updates and deletes workspaces with their variables and tags, and manages runs. It runs locally in Docker over stdio or as a Streamable HTTP server for centralized deployments (with token passthrough, tool filtering and OpenTelemetry metrics), and HashiCorp hosts a remote endpoint. Setup guides cover VS Code, Cursor, Claude Desktop and Claude Code, Codex CLI, Gemini, Amazon Q Developer, Kiro and OpenCode.

Problems it solves

  • my AI assistant writes Terraform with outdated provider arguments
  • let Claude Code look up Terraform Registry modules and provider docs
  • manage HCP Terraform workspaces and runs from an AI assistant
  • an MCP server for Terraform Enterprise that a platform team can run centrally
  • search our private Terraform registry from Cursor

Features

  • public Terraform Registry search for providers, modules and policies, with documentation
  • HCP Terraform and Terraform Enterprise: organizations, projects, private registry
  • workspace create, update and delete with variables, tags and runs
  • stdio and Streamable HTTP transports
  • token passthrough, tool filtering and session modes for centralized deployments
  • OpenTelemetry metrics for tool calls in HTTP mode
  • structured error codes in tool results
  • remote endpoint hosted by HashiCorp
  • setup for VS Code, Cursor, Claude Desktop, Claude Code, Codex CLI, Gemini, Amazon Q Developer, Kiro and OpenCode

Limitations

  • Can expose Terraform data to the connected MCP client and model, so it shouldn't be used with untrusted clients or models.1

Capabilities

Has an MCP serverplan not known

Alternatives

The same job

These do what Terraform MCP Server does.

  1. Open Source MCP Servers for AWS A suite of open source MCP servers that connect AI assistants to AWS services, docs and best practices
  2. Kubernetes MCP Server Native Go MCP server for Kubernetes and OpenShift: CRUD on any resource plus pods, Helm, Tekton and observability tools

Compare Terraform MCP Server with the top 3