azure-cost-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@azure-cost-mcp compare VM prices for D2s v3 across regions"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
azure-cost-mcp
An MCP server that gives Claude live access to Azure pricing and cost data — retail prices, VM comparisons, reservation analysis, architecture estimates, and actual subscription spend.
What it does
Nine tools across two API groups:
Tool | Description | Auth required |
| Search Azure retail prices with OData filters | No |
| Compare VM SKUs across regions (monthly matrix) | No |
| Find cheapest regions for a given SKU | No |
| PAYG vs 1-yr / 3-yr reservation with break-even | No |
| Estimate multi-component architecture monthly cost | No |
| Query actual subscription spend (group by service, resource group, etc.) | Yes |
| Top-N resources by spend with % of total | Yes |
| Cost forecast for a period | Yes |
| List budgets with CRITICAL / WARNING / OK status | Yes |
Related MCP server: cloudscope-mcp
Prerequisites
Node.js 20+
npm
Build
npm install
npm run buildAzure setup (for authenticated tools)
Create a service principal and assign the Cost Management Reader role:
# Create service principal
az ad sp create-for-rbac --name azure-cost-mcp --role "Cost Management Reader" \
--scopes /subscriptions/<SUBSCRIPTION_ID>
# Output includes appId (clientId), password (clientSecret), tenant (tenantId)Claude Desktop configuration
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"azure-cost": {
"command": "node",
"args": ["/absolute/path/to/azure-cost-mcp/dist/index.js"],
"env": {
"AZURE_TENANT_ID": "...",
"AZURE_CLIENT_ID": "...",
"AZURE_CLIENT_SECRET": "...",
"AZURE_SUBSCRIPTION_ID": "..."
}
}
}
}The retail tools work without credentials. Cost Management tools will return setup instructions if credentials are missing.
Environment variables
Variable | Required | Description |
| For auth tools | Azure AD tenant ID |
| For auth tools | Service principal application ID |
| For auth tools | Service principal secret |
| For auth tools | Subscription to query |
| No | Default currency (default: |
Companion skill
A Claude Code skill at ~/.claude/skills/azure-cost.md encodes tool routing rules, the reservation comparison rule, output conventions, and graceful degradation guidance. Install it by copying skills/azure-cost.md from this repository to ~/.claude/skills/.
Development
npm test # run tests
npm run test:watch # watch mode
npm run lint # ESLint
npm run format # PrettierAvailable Tools
9 toolsazure_compare_reservation_vs_paygA
Compare pay-as-you-go vs 1-year and 3-year reservation pricing for a VM SKU. Always call this for workloads expected to run >6 months.
Inputs: armSkuName (required), armRegionName (required), currencyCode, response_format.
azure_compare_vm_pricesA
Compare VM SKUs across regions. Always call azure_compare_reservation_vs_payg after for workloads running >6 months.
Inputs: regions (required), skuNames (required), currencyCode, response_format.
azure_estimate_architecture_costA
Estimate monthly and annual cost for a multi-component Azure architecture. Resolves prices in parallel.
Inputs: components (required), currencyCode, response_format, includeReservationAlternative.
azure_find_cheapest_regionB
Find the cheapest Azure regions for a given VM SKU. Returns top N sorted by price.
Inputs: armSkuName (required), topN, priceType, currencyCode, +1 more.
azure_get_cost_forecastC
Retrieve Azure cost forecast for a period. Requires Cost Management credentials.
Inputs: endDate, startDate, timeframe, granularity, +1 more.
azure_list_budgetsB
List Azure budgets with current spend status (CRITICAL/WARNING/OK). Requires Cost Management credentials.
Inputs: resourceGroup, response_format.
azure_query_costsC
Query actual Azure subscription spend. Requires Cost Management credentials.
Inputs: timeframe (required), endDate, groupBy, costType, +3 more.
azure_query_costs_by_resourceC
Show top-N Azure resources by spend with % of total. Requires Cost Management credentials.
Inputs: topN, endDate, startDate, timeframe, +2 more.
azure_search_pricesB
Search Azure retail prices with OData filters. Use for ad-hoc price lookups.
Inputs: limit, skuName, priceType, armSkuName, +6 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
The tools separate into pricing estimation and actual cost management, but there is some overlap among azure_search_prices, azure_compare_vm_prices, and azure_find_cheapest_region. Descriptions are specific enough that an agent can usually choose correctly, though the boundaries between ad-hoc price lookup and VM-specific comparison could be clearer.
All tool names follow a consistent azure_verb_noun snake_case pattern, with verbs like search, compare, find, estimate, query, get, and list. The naming is predictable and makes the resource/action of each tool immediately recognizable.
Nine tools is well within the ideal range for a focused Azure cost management server. Each tool covers a meaningful aspect of pricing, cost querying, forecasting, or budgeting without unnecessary redundancy or bloat.
The set covers core workflows: price discovery, VM cost comparison, reservation vs pay-as-you-go, architecture estimation, actual spend, resource-level breakdown, forecasting, and budgets. The main gap is budget lifecycle management—only listing budgets is supported, with no create, update, or delete operations, so budget management workflows are incomplete.
Maintenance
Related MCP Connectors
Hosted MCP server for AWS cloud spend: service breakdowns, anomalies, savings and forecasts.
Hosted MCP server for LLM cost estimation, model comparison, and budget-aware routing.
Hosted SQL Server MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Hosted Amazon Seller and Vendor MCP server for Claude, ChatGPT, Cursor, Codex, Gemini, Copilot.
Related MCP Servers
- AlicenseBqualityDmaintenanceAn MCP server for unified cost tracking and analysis across AWS, OpenAI, and Anthropic. It enables users to query expenditures, compare costs across providers, and analyze usage trends through natural language.10MIT
- AlicenseAqualityCmaintenanceCloud cost management MCP server for Azure. Ask your AI about your cloud bill.15149 npm1MIT
- AlicenseAqualityBmaintenanceMCP server that lets Claude (or any MCP-compatible client) compare on-demand compute + storage pricing across AWS, Azure, and GCP in real time.39638 PyPI2MIT
- FlicenseNot gradedqualityDmaintenanceThis MCP server enables querying Azure resource pricing programmatically through a structured workflow, including listing service families, service names, products, and calculating monthly costs.-