
Terraform MCP Server
by hashicorpio.github.hashicorp/terraform-mcp-serverv1.0.0
Terraform ecosystem integration: provider discovery, module analysis and Terraform Registry API access for infrastructure-as-code workflows.
context tax
~2,608 tok/turn9 tools
security
100/100
cold start
253 ms
freshness
Active26d ago
Our reading of Terraform, from the data
Terraform is a cloud platforms MCP server from hashicorp, listed in the official MCP Registry.
Its 9 tools add about 2,608 tokens to every model turn, heavier than the cloud platforms median of 701 tokens across 122 measured servers (measured 2026-10-23).
Maintenance is active: the last public signal was 26 days ago (2026-10-15). For comparison, 62% of cloud platforms servers are active or maintained.
With 1,550 GitHub stars it ranks #15 of 713 cloud platforms servers we index.
It runs locally on your machine over stdio.
Install Terraform MCP server
Install in Claude Code
claude mcp add terraform-hashicorp -- docker run -i --rm docker.io/hashicorp/terraform-mcp-server:1.0.0Install in Cursor
{
"mcpServers": {
"terraform-hashicorp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"docker.io/hashicorp/terraform-mcp-server:1.0.0"
]
}
}
}Add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (project).
Install in Claude Desktop
{
"mcpServers": {
"terraform-hashicorp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"docker.io/hashicorp/terraform-mcp-server:1.0.0"
]
}
}
}Settings → Developer → Edit Config (claude_desktop_config.json), then restart.
Install in VS Code
{
"servers": {
"terraform-hashicorp": {
"type": "stdio",
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"docker.io/hashicorp/terraform-mcp-server:1.0.0"
]
}
}
}Add to .vscode/mcp.json in your workspace.
Install in Windsurf
{
"mcpServers": {
"terraform-hashicorp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"docker.io/hashicorp/terraform-mcp-server:1.0.0"
]
}
}
}Add to ~/.codeium/windsurf/mcp_config.json.
Try it in a sandbox first: this installs it with scripts off and starts it with no network, then lists its tools and token cost. How it works
npx mcpskillhub test docker.io/hashicorp/terraform-mcp-server:1.0.0
Context tax
Connecting this server adds ~2,608 tokens of tool definitions to every model turn (moderate, 9 tools). Measured 2026-10-23 via a sandboxed run; o200k tokenizer, worst case for clients that load all tools up front. How we measure
| Model | Per 1,000 turns | With prompt caching |
|---|---|---|
| Claude Opus 5.5 | $10.43 | $0.522 |
| Claude Sonnet 5.5 | $5.22 | $0.522 |
| Claude Haiku 5.5 | $0.261 | — |
Input prices as of 2026-10-06. Excludes your own prompt and output.
Tools (9)
search_providers442 tokThis tool retrieves a list of potential documents based on the 'service_slug' and 'provider_document_type' provided. You MUST call this function before 'get_provider_details' to obtain a valid tfprovider-compatible 'provider_doc_id'. Use the most relevant single word as the search query for 'service_slug', if unsure about the 'service_slug', use the 'provider_name' for its value. When selecting the best match, consider the following: - Title similarity to the query - Category relevance Return the selected 'provider_doc_id' and explain your choice. If there are multiple good matches, mention
get_provider_capabilities267 tokGet the capabilities of a Terraform provider including the types of resources, data sources, functions, guides, and other features it supports. This tool analyzes the provider documentation to determine what types of capabilities are available: - resources: Infrastructure resources that can be created/managed - data-sources: Read-only data sources for querying existing infrastructure - functions: Provider-specific functions for data transformation - guides: Documentation guides and tutorials for using the provider - actions: Available provider actions (if any) - ephemeral resources: Temporar
search_modules199 tokResolves a Terraform module name to obtain a compatible module_id for the get_module_details tool and returns a list of matching Terraform modules. You MUST call this function before 'get_module_details' to obtain a valid and compatible module_id. When selecting the best match, consider the following: - Name similarity to the query - Description relevance - Verification status (verified) - Download counts (popularity) Return the selected module_id and explain your choice. If there are multiple good matches, mention this but proceed with the most relevant one. If no modules were found, reat
search_policies187 tokSearches for Terraform policies based on a query string. This tool returns a list of matching policies, which can be used to retrieve detailed policy information using the 'get_policy_details' tool. You MUST call this function before 'get_policy_details' to obtain a valid terraform_policy_id. When selecting the best match, consider the following: - Name similarity to the query - Title relevance - Verification status (verified) - Download counts (popularity) Return the selected policyID and explain your choice. If there are multiple good matches, mention this but proceed with the most relev
get_latest_module_version165 tokFetches the latest version of a Terraform module from the public registry
get_module_details119 tokFetches up-to-date documentation on how to use a Terraform module. You must call 'search_modules' first to obtain the exact valid and compatible module_id required to use this tool.
get_policy_details115 tokFetches up-to-date documentation for a specific policy from the Terraform registry. You must call 'search_policies' first to obtain the exact terraform_policy_id required to use this tool.
get_latest_provider_version113 tokFetches the latest version of a Terraform provider from the public registry
get_provider_details109 tokFetches up-to-date documentation for a specific service from a Terraform provider. You must call 'search_providers' tool first to obtain the exact tfprovider-compatible provider_doc_id required to use this tool.
Security signals
100/100 — no known issues found as of 2026-10-23, from the checks below. This is not a guarantee of safety; review what a server can do before connecting it.
Deductions
No findings from the checks that ran.
Checks
- ✓Repository hygiene (archived, activity, license, security policy)
- ✓Tool descriptions (prompt-injection and hidden-text heuristics)
- ○Package metadata (install scripts, provenance) — pending
- ○Source scan (secrets, CVEs, risky code) by vectra-guard — pending
Scan it yourself before installing with vectra-guard, the open-source agent security CLI (made by NavyaAI, which also runs MCPSkillHub). Scoring rules
Freshness
Active — last maintenance signal 26d ago. The newest of the signals below sets the band.
Last commit (default branch)
2026-10-15 · 26d ago · GitHub
Latest release
2026-08-26 · 3mo ago · GitHub · v1.3.0
Package published
no data · npm/PyPI
Registry entry updated
2026-06-10 · 5mo ago · official registry · v1.0.0
How it compares in Cloud Platforms
Against the most-starred cloud platforms servers we index. Token cost is per model turn, measured from each server's live tool list.
| Server | Stars | Tools | Tokens / turn | Freshness | Runs |
|---|---|---|---|---|---|
| Terraform (this) | 1,550 | 9 | 2,608 | Active | local |
| Scrapling | 88,517 | — | not measured | Active | local |
| Corsair Dev | 15,309 | — | not measured | Active | local |
| Plg Handler | 14,805 | — | not measured | Active | — |
| Bedrock KB Retrieval | 9,793 | — | not measured | Active | local |
| Cloudflare | 4,391 | — | not measured | Active | hosted |
FAQ
›How do I install the Terraform MCP server in Claude Code?
Run: claude mcp add terraform-hashicorp -- docker run -i --rm docker.io/hashicorp/terraform-mcp-server:1.0.0. For Cursor, VS Code, Claude Desktop and Windsurf, use the install tabs above.
›Does Terraform require an API key?
No required environment variables are declared in its published metadata.
›Can I use Terraform as a remote (hosted) MCP server?
No hosted endpoint is published; it runs locally over stdio.
›Is Terraform in the official MCP registry?
Yes, as io.github.hashicorp/terraform-mcp-server.
›How many tokens does Terraform add to my context?
Its tool definitions total about 2,608 tokens, resent on every turn.
Sources and method
- Official MCP Registry entry
- updated 2026-06-10
- GitHub repository
- fetched 2026-10-19
- Package registry (npm / PyPI)
- listed
- Tool list (tools/list), measured by us
- 2026-10-23
- Security signals, computed by us
- 2026-10-23
- Last checked against all sources
- 2026-10-19
The description, packages and links come from the maintainer's own published metadata. Token cost, security signals, freshness and the reading above are MCPSkillHub's own measurements; see the methodology. Editorial standards are owned by Ramachandra Vikas Chamarthi, Founder & AI HPC Architect. Spot an error? Request a correction or claim the listing.
Alternatives to Terraform
Other cloud platforms MCP servers.