Data as of

Terraform MCP Server for Claude Desktop: Setup & Config

Claude Desktop: Connect MCP assistants to Terraform Registry data and HCP Terraform or Terraform Enterprise.

What you can do with Terraform in Claude Desktop

Choose it for Terraform Registry research and platform workspace operations through one MCP integration.

  • Look up provider and module information while drafting Terraform configuration.
  • Access private registry information for an existing organization.

Before you start: Terraform in Claude Desktop

  • Docker installed and running
  • An MCP-compatible assistant

This command is the README's local Claude Code Docker launch. HCP Terraform or Enterprise access additionally uses TFE_ADDRESS and TFE_TOKEN, which must be forwarded into the container as shown in the README's client-specific examples. Public Registry use and platform access are distinct configurations.

Terraform Claude Desktop configuration

  1. Choose Claude Desktop configuration scope

    For Terraform MCP Server, open macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\Claude\claude_desktop_config.json. Merge under mcpServers via Settings → Developer → Edit Config when available.

  2. Add Terraform MCP Server to Claude Desktop

    Use the terraform-mcp-server entry below in mcpServers. Keep Terraform MCP Server's documented stdio connection fields and your other Claude Desktop entries.

  3. Check Terraform MCP Server in Claude Desktop

    Terraform MCP Server: Fully quit and reopen Claude Desktop; check developer diagnostics.

Config file · macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

JSON
{
  "mcpServers": {
    "terraform-mcp-server": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "hashicorp/terraform-mcp-server"
      ],
      "env": {}
    }
  }
}

Terraform tools available to Claude Desktop

Terraform's stored tool list documents 2 tools; compare it with Claude Desktop's connected tool list, because the stored list is not a live check.

search_providers

When Claude Desktop requests search_providers from Terraform, review the action before approving it.

Search Terraform providers; named in the README's tool-filtering example.

get_provider_details

When Claude Desktop requests get_provider_details from Terraform, review the action before approving it.

Terraform: full stored tool descriptions

Troubleshooting Terraform in Claude Desktop

  • Fully quit and reopen Claude Desktop for Terraform MCP Server. If docker and a running Docker engine is missing, check the desktop process's PATH, which may differ from your terminal.
  • Terraform MCP Server uses stdio here: Claude Desktop must keep the configured process running; protocol output belongs on stdout and diagnostics on stderr.
  • Known limitation: Connected clients and models may receive sensitive Terraform data.
  • Known limitation: Write-capable platform operations need deliberate permission and tool configuration.
  • Known limitation: The complete tool catalog is linked externally rather than included in the supplied README.
  • General Claude Desktop troubleshooting lives in the /clients/claude-desktop guide.

Terraform MCP Server — details. Claude Desktop guide

Frequently asked questions

Claude Desktop loads Terraform MCP Server from claude_desktop_config.json: ~/Library/Application Support/Claude/ on macOS, or %APPDATA%\Claude\ on Windows. Open it via Settings → Developer → Edit Config when available.

Claude Desktop's terraform-mcp-server example uses stdio.

Terraform MCP Server's Claude Desktop configuration invokes docker and a running Docker engine.

Terraform MCP Server's stored list contains 2 tools, including search_providers, get_provider_details. Compare those names with Claude Desktop's connected tool list; the stored list is not a live check.

No. The README also documents HCP Terraform and Terraform Enterprise workspace and private registry features.

Stdio and streamable HTTP are documented.