Skip to main content
Glama

modelpricing-mcp

ModelPricing License: MIT

Official Model Context Protocol (MCP) server for ModelPricing.xyz. Gives AI coding agents (Cursor, Claude Desktop, Windsurf, Antigravity) live access to 2026 frontier LLM API pricing, KV prompt caching math, and token cost simulations.

Tools Included

  1. list_llm_models — Fetch live 2026 rates across OpenAI, Anthropic, Google, DeepSeek, xAI, and Meta.

  2. calculate_llm_cost — Simulate monthly API costs for any input/output token volume and KV cache hit ratio (0 to 1).

  3. compare_llm_models — Side-by-side cost & savings comparison between any two models with direct links to interactive charts.

Related MCP server: tokencost-mcp-server

Quick Setup (Cursor / Claude Desktop / Windsurf)

Add to your mcp_config.json or claude_desktop_config.json:

{
  "mcpServers": {
    "modelpricing": {
      "command": "npx",
      "args": ["-y", "modelpricing-mcp"]
    }
  }
}

Available Tools

3 tools
calculate_llm_costB

Calculate and rank LLM API costs for a specific token workload with KV prompt caching hit ratio modeling.

Inputs: modelId, inputTokens, outputTokens, cacheHitRatio.

compare_llm_modelsB

Compare two LLM models side-by-side on token cost, prompt caching savings, and context limits.

Inputs: modelA (required), modelB (required), inputTokens, outputTokens, +1 more.

list_llm_modelsA

Fetch live 2026 frontier LLM API pricing, KV prompt caching rates, and context window limits from ModelPricing.xyz.

Inputs: provider.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 3 tools

    Disambiguation4/5

    Each tool has a distinct purpose: list fetches raw pricing data, calculate computes cost for a workload, and compare does a two-model side-by-side. The only mild overlap is between calculate and compare, since both surface cost figures, but the descriptions clearly delineate workload-based ranking versus pairwise comparison.

    Naming Consistency5/5

    All three tools follow a clean verb_noun pattern (list_, calculate_, compare_) on the same domain object (llm_models). The convention is predictable and immediately readable.

    Tool Count4/5

    Three tools is on the thin side but well-matched to a focused pricing-reference server: fetch, compute, and compare cover the core needs without bloat. Slightly more (e.g. a single-model lookup) could round it out, but nothing feels redundant.

    Completeness4/5

    The surface covers the main lifecycle of the domain—retrieve pricing, apply it to a workload, and compare models. Minor gaps exist, such as retrieving one specific model's full details or historical pricing, but these are workable via list_llm_models.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      C
      maintenance
      unofficial MCP (Model Context Protocol) server for Reclaim.ai calendar integration - manage tasks, habits, and smart scheduling through AI assistants like Claude.
      32
      4
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      The official Bitget MCP (Model Context Protocol) server. Gives AI assistants direct, real-time access to the Bitget exchange through natural language.
      237
      MIT
    • A
      license
      B
      quality
      B
      maintenance
      Official MCP server for interacting with Saudi market data (Sahmk) via natural language queries, enabling stock quotes, company info, and market summaries inside AI agents like Cursor and Claude Desktop.
      24
      30 PyPI
      15
      MIT