mcp-server-defillama
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., "@mcp-server-defillama what's the TVL of Uniswap?"
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.
MCP Server for DefiLlama
This repository contains a Model Context Protocol (MCP) server that provides Claude with access to DeFi data via the DefiLlama API. The server enables Claude to perform operations like retrieving protocol TVL data, chain TVL data, token prices, and stablecoin information.
Overview
The MCP server exposes the following tools to Claude:
Protocol Data
defillama_get_protocols: List all protocols tracked by DefiLlamadefillama_get_protocol_tvl: Get TVL data for a specific protocol
Chain Data
defillama_get_chain_tvl: Get TVL data for a specific chain
Token Data
defillama_get_token_prices: Get current prices of tokensdefillama_get_historical_prices: Get historical prices of tokens
Stablecoin Data
defillama_get_stablecoins: List all stablecoins tracked by DefiLlamadefillama_get_stablecoin_data: Get data for a specific stablecoin
Prerequisites
Node.js (v16 or higher)
Related MCP server: DeFi Llama MCP Server
Running the server
Option 1: Using npx (Recommended)
npx @mcp-dockmaster/mcp-server-defillama
You can run the MCP server directly without installation using npx:
This will download and execute the server directly from npm.
Option 2: Manual Installation
Clone this repository:
git clone https://github.com/mcp-dockmaster/mcp-server-defillama.git
Install dependencies:
npm install
Build the project:
npm run build
Claude Usage
To configure Claude Desktop to use this MCP server:
Open Claude Desktop, and navigate to Settings>Developer Settings>MCP Servers. There you'll encounter the button to open the configuration JSON file.
Add the MCP server configuration:
{
"mcpServers": {
"mcp-server-defillama": {
"command": "npx",
"args": [
"@mcp-dockmaster/mcp-server-defillama"
]
}
}
}Alternatively, if you installed the package locally:
{
"mcpServers": {
"mcp-server-defillama": {
"command": "node",
"args": [
"/path/to/your/mcp-server-defillama/build/index.js"
]
}
}
}Available Tools
7 toolsdefillama_get_chain_tvlC
Get TVL data for a specific chain
Inputs: chain (required).
defillama_get_historical_pricesC
Get historical prices of tokens
Inputs: coins (required), timestamp (required).
defillama_get_protocolsA
List all protocols tracked by DefiLlama
Inputs: no named parameters.
defillama_get_protocol_tvlB
Get TVL data for a specific protocol
Inputs: protocol (required).
defillama_get_stablecoin_dataC
Get data for a specific stablecoin
Inputs: asset (required).
defillama_get_stablecoinsA
List all stablecoins tracked by DefiLlama
Inputs: no named parameters.
defillama_get_token_pricesC
Get current prices of tokens
Inputs: coins (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 7 tools
Each tool targets a distinct data type (protocols, protocol TVL, chain TVL, token prices, historical prices, stablecoins, stablecoin data). There is no overlap that would confuse an agent selecting a tool.
All tools follow the exact same verb_noun pattern: defillama_get_<entity>. Naming is uniformly snake_case and descriptive.
With 7 tools, the server is well-scoped for a read-only DeFi data API. Each tool covers a core data category without unnecessary bloat.
The toolset covers the main DefiLlama data categories: protocols, chains, tokens, and stablecoins. Minor gaps exist such as lack of historical TVL or yield/fee data, but the core read operations are present.
Related MCP Connectors
DefiLlama MCP — DeFi analytics from DefiLlama (free, no auth)
Enable AI assistants to interact seamlessly with the DefiLlama API by translating MCP tool calls i…
DeFi TVL, stablecoin supply, perp funding, top coins and prediction-market data as agent tools.
Market and on-chain crypto data for AI agents. Pay per call in USDC on Base (x402).
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceReal-time DeFi data for AI agents. Provides yields, TVL, prices, DEX volumes, fees, and contract data via 8 MCP endpoints, powered by DeFiLlama.-
- AlicenseAqualityFmaintenanceProvides access to DeFi Llama's free API for querying protocol TVL, chain TVL, yields, stablecoins, bridges, DEX volumes, and fees through natural language.820 npmMIT
- AlicenseAqualityDmaintenanceEnables Claude to access real-time NEAR DeFi data for yield comparisons, staking analysis, swap routing, and lending rates, helping users make informed DeFi decisions.5MIT
- AlicenseAqualityCmaintenanceEnables AI agents to interact with DefiLlama's DeFi data aggregator, providing access to TVL, DEX volumes, protocol statistics, and more via the Model Context Protocol.23ISC